<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman,new york,times,serif;font-size:12pt"><div>Hi,<br><br>you have to use somethiong like that:<br>wfs = new OpenLayers.Layer.Vector("mylayer", <br> { styleMap: wfsStyle, <br> strategies: [new OpenLayers.Strategy.Fixed(), ],<br> projection: destproj, <br> protocol: new OpenLayers.Protocol.WFS({ <br><span>
url: "<a target="_blank" href="http://myserver:8080/geoserver/wfs">http://myserver:8080/geoserver/wfs</a>", </span><br><span> featureNS: "<a target="_blank" href="http://www.openplans.org/topp">http://www.openplans.org/topp</a>", </span><br> featureType: "xxxx", <br> geometryName: "SHAPE", <br> srsName: "EPSG:4326", <br>
version: "1.1.0" <br> }) <br> });<br></div><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;"><br>best regards<br>Sarah<br><div style="font-family: times new roman,new york,times,serif; font-size: 12pt;"><font face="Tahoma" size="2"><hr size="1"><b><span style="font-weight: bold;"></span></b><br></font><br>Hi all,<br><br>this is my code and here layer is information of layer that i want to add into the map. can any one help me for this code<br><br>var wfsLayer = new OpenLayers.Layer.Vector(<br> <a
rel="nofollow" target="_blank" href="http://layer.name">layer.name</a><br>
, {<br> strategies: [new OpenLayers.Strategy.Fixed()]<br> , protocol: new OpenLayers.Protocol.WFS({<br> url:this.urlvalue<br> , version: "1.0.0"<br>
, srsName: "EPSG:4326"<br> , featureType: layer.protocol.featureType<br> , featureNS: "<a rel="nofollow" target="_blank" href="http://www.openplans.org/topp">http://www.openplans.org/topp</a>"<br>
})<br> , projection: new OpenLayers.Projection("EPSG:4326")<br> , styleMap: new OpenLayers.StyleMap({<br> strokeColor: "Red",<br>
strokeWidth: 2,<br> strokeOpacity: 0.5,<br> fillOpacity: 0.2<br> }) <br>
</div></div>
</div><br></body></html>