Groups | Blog | Home
all groups > flash (macromedia) > november 2005 >

flash (macromedia) : escape/unescape UTF8 problem with PHP between flash versions



Ads
11/10/2005 11:12:01 PM
I'm developing a multilingual site that requires a contact form that is
actioned by PHP on the server-side.

However, PHP doesn't understand the special characters (?, ? etc) that are
urlencoded by the flash 6 and above players because they are encoded from UTF8
from the text fields in the form by LoadVars.sendAndLoad when sent to the
script to process.

E.g. :-
? is encoded as %C3%A9 in flash 6 + (incorrect for PHP3/4/5 to urldecode)
? is encoded as %E9 in flash 5 (correct for PHP to urldecode)

I need to publish in flash 7 for site functionality.

Obviously I can't change this in-built behaviour of the later versions of
flash - so does anyone know how to decode the UTF8 urlencoded string from flash
so that PHP can process and output the correct characters?

Thanks in advance
Ads
David Powers
11/10/2005 11:15:38 PM
[quoted text, click to view]

Use utf8_decode():

www.php.net/manual/en/function.utf8-decode.php

--
David Powers
Author, "Foundation PHP for Dreamweaver 8" (foED - forthcoming)
Author, "Foundation PHP 5 for Flash" (friends of ED)
AddThis Social Bookmark Button