Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets

This WebDNA talk-list message is from

2010


It keeps the original formatting.
numero = 105787
interpreted = N
texte = --000e0cd5d000ce0349048fe95190 Content-Type: text/plain; charset=UTF-8 Govinda, OK - your page, and the ajax page are being served as UTF-8 - but the post to the db is incorrect. It is encoding the pound symbol as: %27%A3 whereas it should be %C2%A3 I'm no javascript expert but it looks like you shouldn't be using 'escape()' on unicode characters: http://www.dangrossman.info/2007/05/25/handling-utf-8-in-javascript-php-and-non-utf8-databases/ the guy on the link above suggests using 'encodeURIComponent(string)'. Would you not consider building your ajax stuff using the Jquery framework - that's my plan when I get the time to sort it. - Tom --000e0cd5d000ce0349048fe95190 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Govi= nda,

OK - your page, and the ajax page are being s= erved as UTF-8 - but the post to the db is incorrect. =C2=A0 It is encoding= the pound symbol as:

=C2=A0=C2=A0 %27%A3

whereas it should be

=C2=A0=C2= =A0 %C2%A3

I'm no javascript expert but it looks like you shoul= dn't be using 'escape()' on unicode characters:

=C2=A0=C2=A0 =C2=A0http= ://www.dangrossman.info/2007/05/25/handling-utf-8-in-javascript-php-and-non= -utf8-databases/

the guy on the link above suggests using 'encodeURIComponent(= string)'. =C2=A0 =C2=A0Would you not consider building your ajax stuff = using the Jquery framework - that's my plan when I get the time to sort= it.

=
- Tom

=

--000e0cd5d000ce0349048fe95190-- Associated Messages, from the most recent to the oldest:

    
  1. Re: -- SOLVED -- [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  2. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Christer Olsson 2010)
  3. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  4. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Tom Duke 2010)
  5. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  6. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Tom Duke 2010)
  7. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  8. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  9. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Tom Duke 2010)
  10. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  11. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  12. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Tom Duke 2010)
  13. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  14. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
  15. Re: [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Tom Duke 2010)
  16. [WebDNA] encoding with webdna/JS, in context of various file encodings/charsets (Govinda 2010)
--000e0cd5d000ce0349048fe95190 Content-Type: text/plain; charset=UTF-8 Govinda, OK - your page, and the ajax page are being served as UTF-8 - but the post to the db is incorrect. It is encoding the pound symbol as: %27%A3 whereas it should be %C2%A3 I'm no javascript expert but it looks like you shouldn't be using 'escape()' on unicode characters: http://www.dangrossman.info/2007/05/25/handling-utf-8-in-javascript-php-and-non-utf8-databases/ the guy on the link above suggests using 'encodeURIComponent(string)'. Would you not consider building your ajax stuff using the Jquery framework - that's my plan when I get the time to sort it. - Tom --000e0cd5d000ce0349048fe95190 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Govi= nda,

OK - your page, and the ajax page are being s= erved as UTF-8 - but the post to the db is incorrect. =C2=A0 It is encoding= the pound symbol as:

=C2=A0=C2=A0 %27%A3

whereas it should be

=C2=A0=C2= =A0 %C2%A3

I'm no javascript expert but it looks like you shoul= dn't be using 'escape()' on unicode characters:

=C2=A0=C2=A0 =C2=A0http= ://www.dangrossman.info/2007/05/25/handling-utf-8-in-javascript-php-and-non= -utf8-databases/

the guy on the link above suggests using 'encodeURIComponent(= string)'. =C2=A0 =C2=A0Would you not consider building your ajax stuff = using the Jquery framework - that's my plan when I get the time to sort= it.

=
- Tom

=

--000e0cd5d000ce0349048fe95190-- Tom Duke

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

need some help with a loop [nested search?] (1999) RE: protect tag not working (1998) Problems with totals (1997) [WebDNA] Help with STMP Setup using Authentication with Google (2016) Snake Bites (1997) Emailer Timing out (1999) UPS Quick Cost Calculator (1997) [ShowIf] a either fields are blank (1998) WebCat2: Items xx to xx shown, etc. (1997) Error:Too many nested [xxx] contexts (1997) Counting files (1998) [WebDNA] Off topic: ImageMagick (2008) WebCat2 beta 11 - new prefs ... (1997) Caching pages...again (2001) Support ?? (1997) [BoldWords] WebCat.acgib15Mac (1997) Thanks ! (1997) [Webcat 2]Next (1997) Re:HTTP header line is too long? (1997) wierd [cart] action! (1997)