Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid

Re: changing codepage while saving to a text file

by Happy-the-monk (Canon)
on Mar 09, 2006 at 10:58 UTC ( #535370=note: print w/replies, xml ) Need Help??

in reply to changing codepage while saving to a text file

You could use Encode and its friends to change the encoding of your data before writing.

Or you could use the functionality of open that allows you to specify the encoding of your data, as given in the example code open(FH, "<:utf8", "file") (which is for reading - writig will work analogously). I havent used that yet, but it sounds like the right solution.

I don't know about codepages though, I'd suggest you read the Encode documentation on it.

Cheers, Sören

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://535370]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (3)
As of 2018-04-26 00:58 GMT
Find Nodes?
    Voting Booth?