My code for (combining WFS feature info with SLDSelect) like this:
  wfsProtocol = new OpenLayers.Protocol.WFS.v1_1_0({
                          url: layerURL,
                          geometryName: "SHAPE",
                          featurePrefix: layerfeaturePrefix,
                          featureType: layerfeatureType,
                          srsName: "EPSG:900913"
                  });

SLDControl = new OpenLayers.Control.SLDSelect(OpenLayers.Handler.Polygon,
                          {
                              displayClass: 'olControlSLDSelectPolygon',
                              layers:[mylayer]
                          });
                  SLDControl.events.register("selected", this, function(e){
                           wfsProtocol.read({
                             filter: e.filters[0],
                             propertyNames: propNames,
                             callback: processSpatialQuery,
                             scope: strategy
                          });
                  });

The WFS query is working as hoped for. The SLDSelect is not (with or 
without the combined WFS) in the sense that the no highlighted features 
are shown at all. All tiles show blank in firebug.

The Get to WMS look correct and here is the SLD part of the header for 
the request. (It one very long request string). Any ideas?

|<sld:StyledLayerDescriptor xmlns:sld="http://www.opengis.net/sld"; 
version="1.0.0" xsi:schemaLocation||="http://www.opengis.net/sld 
http://schemas.opengis.net/sld/1.0.0/StyledLayerDescriptor.xsd"; 
xmlns:xsi||="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:ogc="http://www.opengis.net/ogc"; 
xmlns:gml="http:||//www.opengis.net/gml"><sld:NamedLayer><sld:Name>gns:PETROLEUM.NZ_2D_SEIS_LINES</sld:Name><sld:UserStyle||><sld:Name>default</sld:Name><sld:FeatureTypeStyle><sld:Rule><ogc:Filter
 
xmlns:ogc="http://www.opengis||.net/ogc"><ogc:Intersects><ogc:PropertyName>SHAPE</ogc:PropertyName><gml:Polygon
 
xmlns:gml="http://www||.opengis.net/gml"><gml:outerBoundaryIs><gml:LinearRing><gml:coordinates
 
decimal="." cs="," ts=" ">18443134||.392446,-6499153.984073 
18571548.599942,-6502822.96143 18555649.698062,-6639798.1160925 
18432127.460375||,-6630014.1764738 
18443134.392446,-6499153.984073</gml:coordinates></gml:LinearRing></gml:outerBoundaryIs||></gml:Polygon></ogc:Intersects></ogc:Filter><sld:LineSymbolizer><sld:Stroke><sld:CssParameter
 
name="stroke"||>#FF0000</sld:CssParameter><sld:CssParameter 
name="stroke-width">2</sld:CssParameter></sld:Stroke></sld||:LineSymbolizer></sld:Rule></sld:FeatureTypeStyle></sld:UserStyle></sld:NamedLayer></sld:StyledLayerDescriptor||>|


-- 
Phil Scadden, Senior Scientist GNS Science Ltd 764 Cumberland St, 
Private Bag 1930, Dunedin, New Zealand Ph +64 3 4799663, fax +64 3 477 5232


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
[email protected]
http://lists.osgeo.org/mailman/listinfo/openlayers-users

Reply via email to