Jump to content

Recommended Posts

i have made a site, intending it to be an online resource for copy and pasting lists in various formats.

a list is pulled from the database and then returned as either a csv, unordered list, xml etc

I am using ajax to update the textarea with the formating for the list, but i am losing, in this instance, french letters.

 

Here is an example: its a list of months in french

 

http://ethickink.co.uk/lists/pages/listdetail.php?id=36

 

when the list first displays it has the accents on letters etc all showing fine, but if you click from the options to list as say an <ul> the foreign letters get broken.

 

if i take the link and open it in a seperate page it displays them fine (http://ethickink.co.uk/lists/pages/returngenlist.php?id=36&action=ul), but i have added a class to the links to allow ajax/jquery to operate instead.

 

my ajax looks like this:

 

$(function() { 
   $('.generatorlink').click( function() { 
         $.get( $(this).attr('href'), function(msg) { 
             $("#listdisplay").text(msg);
         }); 
         return false; // don't follow the link! 
   }); 
}); 

#listdisplay is the text area where the ouput is placed in the main area

  • 3 weeks later...

anyone any ideas?

 

spiderwell I really don't know what I'm talking about here, but in looking at the script the only thing that stands out as a maybe culprit is the use of the clipboard to write your lists. If you've used document.getElementById("listdisplay").innerText = returnedTEXT; and that don't do it I'm out of ideas.

 

PS. 'returnedTEXT' is not the correct words. I would use document.getElementById("listdisplay").innerHTML = httpRequest.responseText; but your doing this in jquery and I don't know the words for that. :shrug:

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.