[OpenLayers-Users] OpenLayers.Protocol.HTTP
christopher.schmidt at nokia.com
christopher.schmidt at nokia.com
Mon Sep 12 20:05:15 EDT 2011
On Sep 12, 2011, at 6:53 PM, ext Robert Sanson wrote:
> I am trying to access a WFS service from a remote server. I have added wfs.data.linz.govt.nz to my proxy.cgi script. Firebug is reporting an error in the response:
>
> <Some unexpected error occurred. Error text was: <urlopen error (10065, 'No route to host')>
This is likely coming from the Proxy script you're using, so you'd have to look
into that. Possibly the server you're using is unable to open connections to
the URL in question. (Look in firebug to see the real underlying URL.)
Sometimes this happens when the server is running under SELinux, or other
permission restriction schemes; in any case, the problem is only going to
be something that you'll debug by looking at what the proxy script sees.
First step would be to get access from the same machine that the proxy is
running on, then to move into Python, then to finally move into Python-under-
Apache and see if there is anything weird at that level.
Good luck.
-- Chris
> Yet, If I take the URL sent and copy it into a Browser URL, I get GML returned correctly. The URL sent is like this:
>
> http://wfs.data.linz.govt.nz/<MY-KEY>/wfs?version=1.0.0&service=WFS&request=GetFeature&maxfeatures=5&typename=x823&bbox=172.5132794038,-43.710577165498,172.65692985022,-43.634349733512
>
> Any ideas why I get this error? My code is:
>
> var parwfs = new OpenLayers.Layer.Vector("WFS Parcels", {
> strategies: [new OpenLayers.Strategy.BBOX()],
> protocol: new OpenLayers.Protocol.HTTP({
> url: "http://wfs.data.linz.govt.nz/<MY-KEY>/wfs",
> headers: {"Content-Type": "plain/text"},
> params: {
> version: "1.0.0",
> service: "WFS",
> request: "GetFeature",
> //srsName: "EPSG:2193",
> maxfeatures: "5",
> typename: "x823"
> },
> format: new OpenLayers.Format.GML()
> }),
> projection: new OpenLayers.Projection("EPSG:4326"),
> style: {strokeColor: "green", strokeWidth: 2, strokeOpacity: 0.5},
> minScale: 50000,
> visibility: false
> });
> map.addLayer(parwfs);
>
> Many thanks,
>
> Robert Sanson
>
>
> This email and any attachments are confidential and intended solely for the addressee(s). If you are not the intended recipient, please notify us immediately and then delete this email from your system.
>
> This message has been scanned for Malware and Viruses by Websense Hosted Security. www.websense.com
>
> _______________________________________________
> Users mailing list
> Users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/openlayers-users
More information about the Users
mailing list