[OpenLayers-Users] Ajax.Request and charset problem
Erik Uzureau
erik.uzureau at metacarta.com
Wed Jun 20 19:01:49 EDT 2007
Arnd,
I dont know much about charsets or exactly what your problem is, but
it might be helpful to know that the OpenLayers.Ajax class is a direct
copy of the Ajax class from Prototype.js.
The Prototype framework has a pretty good documentation page that
might help you to get help with your problem:
http://www.prototypejs.org/api/ajax
Erik
On 6/20/07, Arnd Wippermann <arnd.wippermann at web.de> wrote:
> Hello list,
>
> I have problems to get the right response with Ajax.
>
> This is a line, i get from Mapserver with the GetFeatureInfo-Request:
> LINES|289|Böhler Weg - Obere Böhle|2|TREPPE|87|6|7|SG07_Böhler...
>
> With firebug I can see, that the content-type is text/html and the charset
> ISO-8859-1.
>
> I want to use Ajax to fetch the GetFeatureInfo-Request, parse the line,
> build some html and put it in the web side.
>
> When I try to get the result with an Ajax.Request call, i get ? instead of
> ö.
>
> This is the request, I use:
>
> var myAjax = new OpenLayers.Ajax.Request(
> theUrl,
> {
> method: 'get',
> parameters: theParams,
> requestHeaders: ['Content-Type', 'text/html', 'charset',
> 'ISO-8859-1'],
> onComplete: showResponseWMSGetFeatureInfo,
> onFailure: showResponseFailureWMSGetFeatureInfo
> });
>
> Firebug shows for the headers, the same as above.
>
> I have looked into the Ajax-code, googled for an answer, tried utf-8 and so
> on, but i have nothing found, what helps.
>
> My hope is, that someone here have an idea to get the right chars.
>
>
> Mit freundlichen Grüssen
>
> Arnd Wippermann
> http://gis.ibbeck.de/ginfo/
>
> _______________________________________________
> Users mailing list
> Users at openlayers.org
> http://openlayers.org/mailman/listinfo/users
>
More information about the Users
mailing list