in reply to UTF8 and printing to HTML
(BTW, you seem to be right, the intent of the original text is to convey utf8 characters -- in this case, by converting each byte of each "wide" utf8 character as a sequence of hex byte values prefixed by "%".)use Encode; # ... # assuming the source string is in $_: s/%([0-9A-F]{2})/chr(hex($1))/egi; # convert "%HH" to binary bytes $_ = decode( 'utf8', $_ ); # flag the string as utf8 data
|
|---|