Alden Bates (abates) wrote,
Alden Bates
abates

Perl help needed

Here's my problem. I have a plugin I've written for Movable Type, which takes the page MT generates and splits it up into a bunch of subpages. The problem is that in doing this all the UTF8 characters get boned and converted into US-ASCII or something.

For instance, ß, which in UTF8 is 0xC39F, turns into 0xDF.

How do I get it to stop doing this? For the short term, I have inserted calls to utf8::encode from the UTF8 module before I write the string out, to convert them back to UTF8, however I'd really like to fix the thing so it doesn't convert the strings to US-ASCII in the first place.

From what I can tell, Perl does something to mark strings as UTF8 somehow, so I should maybe do something along those lines? I don't know.
Tags: programming is a bastard
Subscribe

  • Hi Livejournal

    Long time, no write. I hope everyone is keeping safe from the pandemic and not going out much. I started working from home earlier this week when…

  • Wait

    What happened to my friends page? Clearly I have been away from LJ too long and they have changed things. Look, I'm a big subscriber to the idea…

  • I've been playing Fallout 3 a bunch recently

    I'm playing it as an evil character because I already did a good playthrough. Reminds me of someone...

  • Post a new comment

    Error

    Comments allowed for friends only

    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

  • 6 comments