in reply to utf8 problems
The description of your problem is a little vague. Naturally, a little of the actual code that demonstrates the problem would be very helpful. Specifically, I'd be interested in knowing:
- What happens in your code that qualifies an HTTP request as "the first time a call is made" vs. "the second time"
- Where does said "string" come from and are you explicitly storing it somewhere in between the "first" and "second" calls
- What character encoding are you sending to the browser as part of the Content-type HTTP header
- What do you mean when you say that "utf-8 chars on the screen ... only show properly if you put your browser decoding back to latin1" (more specifically, how do you know they're utf-8 characters if they display correctly when you tell your browser they're latin1?)
- Have you tried using Encode::_utf8_on() Encode::decode_utf8() to convert the data from a bytestring to the UTF-8 data that bytestring represents?
- Have you compared Devel::Peek::Dump() output on the string from the "first" to the "second" calls to see what is different about the underlying data
- UPDATE: Are you explicitly storing/retrieving something in an APR::Table or just assuming that mod_perl is using it in some way behind the scenes
Hopefully those items will help us all figure out what's causing your problem!
-- Brian