Hello all,
I've looked at Peter Robbins' example of a persistent layer using GeoJSON (http://maps.peterrobins.co.uk/files/ol6.html) which is well behaved. I've been trying to duplicate the entire structure. I have my own IIS 7.5 running on Windows 7 which in turn is connected to a SQL Server 2008 DB. Once I can get OpenLayers to send the right query to IIS, I'll be away to the races. Here's what's confounding me. The working example issues a GET to retieve the GeoJSON data. The vector layers is defined like this: var vectorLayer = new OpenLayers.Layer.Vector("Line Vectors", { styleMap: sm, eventListeners: { "featuresadded": dataLoaded }, strategies: [ new OpenLayers.Strategy.Fixed(), saveStrategy ], protocol: new OpenLayers.Protocol.HTTP({ url: "/cgi-bin/fs/workspace/", format: new OpenLayers.Format.GeoJSON({ ignoreExtraDims: true, internalProjection: map.baseLayer.projection, externalProjection: wgs84 }) }) }); My code only issues an OPTIONS request to the web server, something the working example never does. If I step through the OpenLayers code with Firebug, not only do I not see the OPTIONS request, I don't see anything hitting the webserver at all. My vector layer is defined like this: var vectors = new OpenLayers.Layer.Vector("Vector Layer", { style: { strokeColor: "blue", strokeWidth: 3, cursor: "pointer" }, eventListeners: { "featuresadded": dataLoaded }, strategies: [ new OpenLayers.Strategy.Fixed(), saveStrategy ], protocol: new OpenLayers.Protocol.HTTP({ url: "http://10.0.1.26/roads.aspx", format: new OpenLayers.Format.GeoJSON({ ignoreExtraDims: true, internalProjection: map.baseLayer.projection, externalProjection: wgs84 }) }) }); If someone can help me understand why OpenLayers is requesting "OPTIONS" from the server (which I can't even see from grepping or stepping through the code), and what I might need to go in order to get these two piece glued together, I would really appreciate it. Many thanks in advance, Nathan Silver
_______________________________________________ Users mailing list Users@openlayers.org http://openlayers.org/mailman/listinfo/users