Results 1 to 2 of 2

Thread: Ajax Tabs Content script

  1. #1
    Join Date
    Sep 2007
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Ajax Tabs Content script

    1) Script Title: Ajax Tabs Content script

    2) Script URL (on DD): http://www.dynamicdrive.com/dynamici...tent/index.htm

    3) Describe problem: The problem is simple but i couldnt solve it. i want to use ajax tabs content in my site so i downloaded it... there is 1 demo page and 4 external pages.i wrote the content in the ajax tabs content and saved it and when i opened it on the explorer 6.0 i see Turkish letters ( ü ş İ ö ) dont seem normal... then i re open demo page and make this :

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=windows-1254">
    <head>


    then i saved and than its ok Turkish letters is ok now... but the problem is i dont know what to do for external pages... i tryed pasting same code but it didnt work... demo page is ok now but i still cant see Turkish letters on external pages .

    note : when i open external pages by itself in a explorer Turkish letters is ok but when i try to see external pages with ajax tabs script Turkish letters dont seem normal... Ty for help.

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    The charset issue with Ajax has been discussed in a few past threads as well. To be honest I've never really looked into it, but based on a search on Google, the solution seems to vary, from calling:

    Code:
    httprequest.overrideMimeType('text/html; charset=windows-1254')
    before the Ajax request is sent inside the .js file, to using scripting to do a search and replace of the offending characters.

    The first suggestion might be worth a try. Inside ajaxtabs.js, make the following change (in red):

    Code:
    if (page_request.overrideMimeType)
    httprequest.overrideMimeType('text/html; charset=windows-1254')
    var ullist=targetobj.parentNode.parentNode.getElementsByTagName("li")
    Test this out in Firefox to see if it makes a difference.

Bookmarks

Posting Permissions

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