Re: Baffling unicode wierdness

[prev] [thread] [next] [Date index for 2005/05/18]

From: Graeme St.Clair
Subject: Re: Baffling unicode wierdness
Date: 20:08 on 18 May 2005
I would throw the sterling sign out of the source document, and substitute 
£ or £ or £ (semi-colon is important!).  I think that would 
probably work across all platforms and browsers.

HTH, rgds, GStC.

----- Original Message ----- 
From: "angie ahl" <angie.ahl@xxxxx.xxx>
To: <modperl@xxxx.xxxxxx.xxx>; <beginners@xxxx.xxx>
Sent: Wednesday, May 18, 2005 3:39 PM
Subject: Baffling unicode wierdness


Hi List

I've been pottering away trying to get utf-8 behaving on my set up and
have nearly got there but then the client phoned up saying that the £
symbol was being displayed as a ?

The first page contains several languages and a £ sign and all is
displayed fine.

http://perl.wtsbroadcast.com/about/Angies_test_page.html


The second is the same as the first but without all the extra language
stuff. There the £ displays as a ?.

http://perl.wtsbroadcast.com/about/Angies_second_test_page.html


Very wierd. Same code generated both pages. To explain the whole set
up would take a *long* time but I wondered if anyone else had seen
this?

$v = $q->url_param('fieldname');

my $decoder = Encode::Guess->guess($v);
ref($decoder) or warn "Can't guess for $v: $decoder"; # trap error this way
if (ref($decoder)) {
my $utf8 = $decoder->decode($v) ? $decoder->decode($v) : $v;
$params{$uarg} = $utf8;
}
else {
$params{$uarg} = decode("utf8", $v) ? decode("utf8", $v) : $v;
}


I just can't fathom this.


MP1/Apache 1 on fedora core 2.

        -- 
        To unsubscribe, e-mail: beginners-unsubscribe@xxxx.xxx
For additional commands, e-mail: beginners-help@xxxx.xxx
<http://learn.perl.org/>; <http://learn.perl.org/first-response>;




Baffling unicode wierdness
angie ahl 19:39 on 18 May 2005

Re: Baffling unicode wierdness
Graeme St.Clair 20:08 on 18 May 2005

Re: Baffling unicode wierdness
angie ahl 20:19 on 18 May 2005

Re: Baffling unicode wierdness
Jay Savage 21:36 on 18 May 2005

Re: Baffling unicode wierdness
Randy Kobes 04:10 on 19 May 2005

Re: Baffling unicode wierdness
angie ahl 14:48 on 19 May 2005

Re: Baffling unicode wierdness
Markus Wichitill 22:30 on 19 May 2005

Re: Baffling unicode wierdness
Markus Wichitill 22:38 on 18 May 2005

Generated at 15:53 on 25 May 2005 by mariachi v0.52