[Geoserver-users] IE / Mozilla GetFeatureInfo

Hello, this is my first mail here…

My question is related to GetFeatureInfo…
I have been trying to make it work for many days reading mailing lists and such, so apologies in advance if its an old subject, but I couldn’t solve it yet…

When clicking on a feature in the Demo Preview of GeoServer interface it’s OK, but when copy the exact same code to a local .html it stays with the “Please wait…” for ever. I use Mozilla, havent used IE since I started with this web-mapping… but today I dont know why today I tried my GetFeatureInfo in IE, and it works!!! so… what’s the matter? any comments? how to fix it for Mozilla?

Thanx in advanced

Virginia.


What can you do with the new Windows Live? Find out

Hi,

this is actually the web browser trying to protect you. Not sure why IE is letting you do it, but it may be configured to make exceptions for local files.

Not sure if you are familiar with XSS (Cross Site Scripting). It's an attack where you put JavaScript on other people's webpages. To protect against this, the major browser vendors implemented rules that only let JavaScript send XML requests to the same server the JavaScript was loaded from.

So when you view the original demo, the JavaScript is loaded from http://<where geoserver runs>/geoserver/<somewhere> and the requests for getfeatureinfo go to http://<where geoserver runs>/geoserver/<somewhere else>. When you save the file to your local harddrive you create a mismatch between the two addresses. You can probably see the security error message if you open Tools-> Error Console.

The simplest solution is to put the files into the www directory in your geoserver data directory. Those files then are accessible through http://<where geoserver runs>/geoserver/www/

-Arne

virginia antonijevic wrote:

Hello, this is my first mail here...

My question is related to GetFeatureInfo...
I have been trying to make it work for many days reading mailing lists and such, so apologies in advance if its an old subject, but I couldn't solve it yet....

When clicking on a feature in the Demo Preview of GeoServer interface it's OK, but when copy the exact same code to a local .html it stays with the "Please wait...." for ever. I use Mozilla, havent used IE since I started with this web-mapping... but today I dont know why today I tried my GetFeatureInfo in IE, and it works!!! so... what's the matter? any comments? how to fix it for Mozilla?

Thanx in advanced

8)
Virginia.

--
Arne Kepp
OpenGeo - http://opengeo.org
Expert service straight from the developers