Javascript client classes IE8 CORS error

This forum deals with any kind of web based client technology, whether it is the well known java script based Ajax servlet or the upcoming approaches such as Leaflet, OpenLayers and so on.
Post Reply
ASOL
Posts: 5
Joined: Thu Oct 25, 2018 9:32 am

Javascript client classes IE8 CORS error

Post by ASOL »

Hello,

I have to use IE8 compatibility mode in my aspx Site and im trying to implement the PTV functions with Javascript Client Classes.
Now im trying initialize the xMapClient and set the credentials and there Comes the error: "This browser does not support CORS with basic authentication." xmap-client.js (259,5)

Code: Select all

  mapClient = new XMapClient('https://xmap-eu-n-test.cloud.ptvgroup.com/xmap');
            mapClient.setCredentials(xtok, token);
Im not really sure how to solve the CORS Problem in ie8.
User avatar
Oliver Heilig
Posts: 154
Joined: Tue May 13, 2014 12:10 pm
Location: Karlsruhe, Germany
Contact:

Re: Javascript client classes IE8 CORS error

Post by Oliver Heilig »

Hello,

we don't support IE8 for xServer-JavaScript client anymore. I recommend using the xMap-1 WMS servlet instead PTV clients, so you don't have any CORS issues (even with IE8). Read here for samples how to include them into browser maps.

https://github.com/ptv-logistics/xserve ... ate/xmap-1

Or use the new rest/tile API for xMap-2

https://github.com/ptv-logistics/xserve ... ilerplate/

For all other xserver1/2 APis i recommend to use plain ajax + jQuery instead of the PTV xServer clients, see

http://xserver.ptvgroup.com/en-uk/cookb ... -json-api/

Oli
Oliver Heilig
Chief Developer Logistic Services
PTV GROUP - Germany

https://github.com/oliverheilig/
Post Reply