Rosen wrote: > I have one very big problem: I create website with english and greek > language. I use "iso-8859-1" encoding for my website. > I show the greek language text with encoded chars like > "τηλεόρα&si;" Representing such characters as HTML entities is fine. > On the website I have no problems - everything shows ok, but when I pass > this greek encoded string to javascript - i.e. "alert('τη');" the > browser doesn't decode the greek symbols and the alert shows me the same > :"τη" The data between <script> and </script> is, in HTML documents, CDATA, so HTML entities are not decoded. You either have to encode the document using a character encoding which supports the characters you want (such as UTF-8), configure your server to emit a suitable HTTP header, and use literal versions of those characters or represent those characters as \uXXXX (where XXXX is the Unicode character specified by four hexadecimal digits), or \XXX (three octal digits representing the Latin-1 character), or \xXX (two hexadecimal digits representing the Latin-1 character). -- David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/> Home is where the ~/.bashrc is -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php