[OpenLayers-Users] Unable to project WFS properly
Smaran Harihar
smaran.harihar at gmail.com
Mon Sep 24 22:29:46 PDT 2012
I did change it to WFS.v1_1_0 but for some reason I keep getting this error,
TypeError: e.features is null
in the function,
function processSpatialQuery(e)
{
//output data here
alert(e.features[0].attributes.Orig_AddrKey);
}
Why is it not collecting any data?
Thanks,
Smaran
On Mon, Sep 24, 2012 at 2:12 PM, Phil Scadden <p.scadden at gns.cri.nz> wrote:
>
>
>
> var pimaWFS = new OpenLayers.Layer.Vector("Pima Pine", {
> strategies: [new OpenLayers.Strategy.BBOX()],
> protocol: new OpenLayers.Protocol.WFS({
> url: "http://128.196.142.12:8080/geoserver/wfs",
> featureType: "PimaPine",
> featureNS: "http://opengeo.org",
> srsName: "EPSG:4326"
> })
> });
>
> But still I have no luck despite specifying the srsName.
>
> Nope. You MUST tell it to use v1_1_0 or srs isnt honoured.
> ie protocol: new OpenLayers.Protocol.WFS.v1_1_0({
>
>
> My Geoserver is 2.1 and seems to be the latest build. How can I check if
> it supports WFS 1.1.0 or not??
>
> It supports 1.1 (you get details of what a server supports from
> WFSGetcapabilities call.
>
>
> Notice: This email and any attachments are confidential. If received in
> error please destroy and immediately notify us. Do not copy or disclose the
> contents.
>
>
>
> _______________________________________________
> Users mailing list
> Users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/openlayers-users
>
>
--
Thanks & Regards
Smaran Harihar
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/openlayers-users/attachments/20120924/f48e00af/attachment.html>
More information about the Users
mailing list