www.webdeveloper.com
Results 1 to 4 of 4

Thread: Extended characters in AJAX response

  1. #1
    Join Date
    Aug 2009
    Posts
    10

    Extended characters in AJAX response

    Hi,

    I am reading one .htm page using XMLHTTP and printing it onto some another page. Page is being read properly but issue is with display.

    htm page I am reading contains extended characters like , , , , , etc. which are being displayed as �in firefox and square boxes in IE.

    The actual page I am reading is : http://bulletlink-e5.com/article.htm

    and the page which reads above page using AJAX and displays is : http://bulletlink-e5.com/d.htm

    Please let me know how to fix this issue.

    Thanks in advance.

  2. #2
    Join Date
    Dec 2003
    Location
    Bucharest, ROMANIA
    Posts
    15,428
    Use UTF-8 both in DB and in meta characters of your web document. Use the UTF-8 encoder method of your server-side language (PHP, ASP, etc...).

  3. #3
    Join Date
    Aug 2009
    Posts
    10
    Hi,

    Thanks for your reply. But its a static .htm file now. There is no connection with database. I am just reading these static .htm files using AJAX.

    You can see static file: http://bulletlink-e5.com/article.htm
    and file which reads above page: http://bulletlink-e5.com/d.htm

  4. #4
    Join Date
    Dec 2003
    Location
    Bucharest, ROMANIA
    Posts
    15,428
    Both your documents have charset iso-8859-1. make them UTF-8
    Code:
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    But... Your code works a little bit illegal, as it writes on the body of a document some parts of the other document (like meta tags) which normally stay in the HEAD, not in the body.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles