473,461 Members | 2,126 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Special characters problem in with Prototype Ajax

Hi, i'm working on an ASP project with prototype.js but i just can't
get special chars to work as they should.
I'm using UTF-8 pages but as soon as i call a page containing for
example å,ä,ö, < or it's replaced with a questionmark.
I call the pages using
new Ajax.Updater(target, page, {asynchronous:true, evalScripts:true});
Any ideas?

Nov 10 '06 #1
2 3330
di*****@styleish.net wrote:
Hi, i'm working on an ASP project with prototype.js but i just can't
get special chars to work as they should.
I'm using UTF-8 pages but as soon as i call a page containing for
example å,ä,ö, < or it's replaced with a questionmark.
I call the pages using
new Ajax.Updater(target, page, {asynchronous:true, evalScripts:true});
Any ideas?
You will get better help on Prototype in the Ruby on Rails Spin-offs
group:

<URL: http://groups.google.com/group/rubyonrails-spinoffs >

--
Rob

Nov 10 '06 #2
di*****@styleish.net a écrit :
Hi, i'm working on an ASP project with prototype.js but i just can't
get special chars to work as they should.
I'm using UTF-8 pages but as soon as i call a page containing for
example å,ä,ö, < or it's replaced with a questionmark.
I call the pages using
new Ajax.Updater(target, page, {asynchronous:true, evalScripts:true});
Any ideas?
This is not a Prototype problem, and neither is a Javascript one ; I
found out that, when using accented characters (é, è, à, ô, etc.)
ISO-8859-1 work better, as UTF-8 treats those characters as two-bytes
characters, etc.

My two advices for this kind of problem are :

1) try different encodings
2) escape your characters with HTML entitites ; i.g. é = &eacute;, è
= &egrave;
Good luck !

-Yanick

Nov 11 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: arno | last post by:
Hi, I want to search a substring within a string : fonction (str, substr) { if (str.search(substr) != -1) { // do something } }
2
by: chuck | last post by:
Hi, Firstly, I don't know if this is just and isolated thing with the prototype.js library or is a problem in general with ajax calls with a '+' character, so i am posting it here. I am...
45
by: bigdadro | last post by:
I've created a new class using prototype.js. After I make the ajax.request all references to this.myClassMethodorVariable are lost. Does the ajax method blow out the object persistance? I'm fairly...
5
by: dougwig | last post by:
I'm trying to handle the scenario where a user's session times out and and their ajax request triggers a redirection by the webserver (302 error?). I'm using Prototype 1.4 and the my works great...
31
by: Tony | last post by:
I just noticed that prototype.js is one of the files in the Ajax.NET distribution - I'm pretty concerned about this. Does anyone know if this is the same "prototype.js" that is not well-liked...
5
by: Gerry Vandermaesen | last post by:
Hi, Does anyone have a freely available JavaScript JSON stringifier. So far my search has been in vain, the one offered on http://www.json.org/json.js does not seem to work for me.
23
by: Dautkhanov | last post by:
Hello ! Does anybody have cutted version of prototype.js with the AJAX functionality only? I am a new in prototype.js topic, so I think this task should be done by other developers. Maybe...
3
by: jacobstr | last post by:
I've noticed Object.extend used in a few different ways and I'm having trouble distinguishing why certain usages apply to a given situation. On line 804 Ajax.Base is defined as follows: ...
7
xNephilimx
by: xNephilimx | last post by:
lHi guys! I'm having a little problem that's getting on my nerves, I couldn't find a solution, I also tryed googling it and I found nothing... (my field of expertise is in AS 2 and 3, but I still...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.