![]() |
|
laziness, impatience, and hubris | |
PerlMonks |
Re^5: UTF8 issue when getting website via LWP::UserAgent in Perlby ultranerds (Hermit) |
on May 12, 2016 at 15:13 UTC ( #1162869=note: print w/replies, xml ) | Need Help?? |
Hi,
Mmm.. its almost like its being double encoded... Here is an example:
...which gives me: GOT TITLE BEFORE: Румыния не будет участвовать в Евровидении-2016 из-за денег - Газета.Ru GOT TITLE: мния не бде асвова в «вовидении-2016» из-за денег - азеа.Ru BLA 1: мния не бде асвова в «вовидении-2016» из-за денег - азеа.Ru After grabbing it back from the DB, if I do this: $test->{title} = decode("utf-8",$title); ...then it works! But it seems bonkers to have to do that, when it should be in utf8 already. Is there a way to "check" if a string has the correct utf8 markers? Thanks! Andy
In Section
Seekers of Perl Wisdom
|
|