From: Justin W. <ju...@24...> - 2003-07-11 01:29:58
|
Not really, see the problem here is what if the character set IS=20 ISO-8859-1 AND uses characters in the >127 byte code range (Where UTF-8=20= kicks it). When you decode that string those characters >128 get=20 turned into ?'s. We are using utf8_encode/decode, the problem is how do you determine if=20= the string actually uses utf8 characters efficiently in php. Justin On Thursday, July 10, 2003, at 07:50 PM, mobiel nederflash wrote: > You can convert in php just like that: > utf8_decode -- > Converts a string with ISO-8859-1 characters encoded with UTF-8 to > single-byte ISO-8859-1. > Description > string utf8_decode ( string data) > > and > > utf8_encode -- encodes an ISO-8859-1 string to UTF-8 > Description > string utf8_encode ( string data) > > Hope that helps ;) > > Folkert > www.swapdepths.nl (dutch language) > www.designhulp.nl (dutch language) > > -----Oorspronkelijk bericht----- > Van: amf...@li... > [mailto:amf...@li...] Namens Alessandro > Crugnola *sephiroth* > Verzonden: vrijdag 11 juli 2003 0:15 > Aan: amf...@li... > Onderwerp: Re: [amfphp] Justin? > > > creating from zero an application using amfphp and new bd tables=20 > there's no > problem, but when someone try to use existing db tables which records=20= > are > not utf8 encoded come the problem.. A solution could be create an=20 > array from > the mysql recordset and converting to utf8 before send it to the = amfphp > serializer. Otherwise add a method in the gateway which give the=20 > possibility > to choose using or not the utf8 default enc/decoding ? > > > Alessandro Crugnola [sephiroth] > Flash | PHP Developer > http://www.sephiroth.it > > Team Macromedia Volunteer for Flash http://www.macromedia.com/go/team > > Flash-php mailing list > http://www.flash-php.it/index.php?ml=3Dfpcoders&action=3Dsubscribe > > ----- Original Message ----- > From: "Justin Watkins" <ju...@24...> > To: <amf...@li...> > Sent: Thursday, July 10, 2003 6:23 PM > Subject: Re: [amfphp] Justin? > > >> What encoding is the data living in the database table. The reason >> for the utf8 encoding/decoding is Flash uses utf8 by default. I >> believe that if the data stored in your table IS utf8 encoded >> everything should run fine. I am actually no expert at = multi-language >> conversions. The only thing I know is uft8 was designed to handle >> most character sets. >> >> I'm not quite sure how to handle data that is NOT utf8 encoded, or if >> there is a way in php to determine whether or not the data is utf8 >> encoded? >> >> Any suggestions. >> >> Justin >> >> >> >> >> ----- Original Message ----- >> From: "Roberto M. Bas=E1=F1ez Gonz=E1lez" <rba...@ma...> >> To: <amf...@li...> >> Sent: Thursday, July 10, 2003 10:35 AM >> Subject: [amfphp] Justin? >> >> >> Justin: >> >> Which is the correct method of get extended characters from AMFPHP? >> >> Examples: >> >> the word "t=E9cnicos" (technical) appear in the result as = "t?cnicos"=20 >> . >> the word "ma=F1ana" (tomorrow) appear in the result as "ma?ana" . >> >> >> I changed the code in line 36 of mysqlAdapter.php as show below and >> get the correct characters: >> >> $line[$key] =3D $value; ( I take off "utf8_decode" ) >> >> But I believe than it is not the correct way. >> >> >> Tx, Roberto. >> >> >> >> ------------------------------------------------------- >> This SF.Net email sponsored by: Parasoft >> Error proof Web apps, automate testing & more. >> Download & eval WebKing and get a free book. >> www.parasoft.com/bulletproofapps >> _______________________________________________ >> amfphp-general mailing list amf...@li... >> https://lists.sourceforge.net/lists/listinfo/amfphp-general >> >> >> >> ------------------------------------------------------- >> This SF.Net email sponsored by: Parasoft >> Error proof Web apps, automate testing & more. >> Download & eval WebKing and get a free book. >> www.parasoft.com/bulletproofapps1 >> _______________________________________________ >> amfphp-general mailing list amf...@li... >> https://lists.sourceforge.net/lists/listinfo/amfphp-general >> >> > > > > > > ------------------------------------------------------- > This SF.Net email sponsored by: Parasoft > Error proof Web apps, automate testing & more. > Download & eval WebKing and get a free book. > www.parasoft.com/bulletproofapps1 > _______________________________________________ > amfphp-general mailing list amf...@li... > https://lists.sourceforge.net/lists/listinfo/amfphp-general > > > > > ------------------------------------------------------- > This SF.Net email sponsored by: Parasoft > Error proof Web apps, automate testing & more. > Download & eval WebKing and get a free book. > www.parasoft.com/bulletproofapps1 > _______________________________________________ > amfphp-general mailing list > amf...@li... > https://lists.sourceforge.net/lists/listinfo/amfphp-general > |