you will need to include proj4js to transform between projections if you are not working with EPSG:4326 or EPSG:900913<br><br>See: <a href="http://trac.openlayers.org/wiki/Documentation/Dev/">http://trac.openlayers.org/wiki/Documentation/Dev/</a> for more info.<br>

<br>Also. On your map options you have:<br>projection: &quot;ESPG:32639&quot;<br><br>it should be:<br>projection: new OpenLayers.Projection(&quot;EPSG:32639&quot;)<br><br>And I would recommend you also add projection to your layer options. It is not necessary in this case, because it seems your map and your wfs layer are in the same projection, but it is a good practice imho.<br>

<br>wfs = new OpenLayers.Layer.WFS(&quot;WFS&quot;,<br>
                                &quot;<a href="http://localhost:8080/geoserver/wfs" target="_blank">http://localhost:8080/geoserver/wfs</a>&quot;, {<br>
                                        typename : &quot;naji:TBL_GIS_FEATURE_POINT&quot;,<br>
                                        maxfeatures : 1000,<br>
                                        format : OpenLayers.Format.GML.v2<br>
                                },<br>                               {projection: new OpenLayers.Projection(&quot;EPSG:32639&quot;)});<br><br><br><div class="gmail_quote">On Wed, Nov 18, 2009 at 5:31 AM, maimaj <span dir="ltr">&lt;<a href="mailto:maimaj@gmail.com">maimaj@gmail.com</a>&gt;</span> wrote:<br>

<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
<br>
Thanks for your help in the first step. You&#39;ve been right, the problem was<br>
with projection. It&#39;s resolved but the WFS features do not show up.<br>
<br>
Before you mentioned that it might be a projection problem, I copied the<br>
request string (obtained by getFullRequestString function of WFS class) in<br>
the address bar and I received a GML2 file with some features. However, that<br>
request string doesn&#39;t include the BBOX parameter.<br>
<br>
I took your advice and fixed the SRS settings on the server and client. When<br>
I copy the request string (obtained from the log file of the Geoserver which<br>
has the BBOX parameter in it) to the address bar, the returned GML2 file<br>
contains only those features which are in the BBOX. Before fixing the<br>
projection problem, this file doesn&#39;t have any feature member (an almost<br>
empty GML2 file).<br>
<br>
As I mentioned before, I cannot see the features on the screen yet. The SRS<br>
settings on the server for this layer are as follows:<br>
  native srs: EPSG:32639<br>
  declared srs: EPSG:32639<br>
  srs handling: keep native<br>
<br>
And my script is the following:<br>
<br>
var map, layer, wfs;<br>
        function init() {<br>
                var bounds = new OpenLayers.Bounds(431834.067, 3887548.528, 684784.466,<br>
                                4002241.703);<br>
                var options = {<br>
                        maxExtent : bounds,<br>
                        maxResolution : 859.9516562499998,<br>
                        projection : &quot;EPSG:32639&quot;<br>
                };<br>
<br>
                map = new OpenLayers.Map(&#39;map&#39;, options);<br>
<br>
                layer = new OpenLayers.Layer.WMS(&quot;OpenLayers WMS&quot;,<br>
                                &quot;<a href="http://localhost:8080/geoserver/wms" target="_blank">http://localhost:8080/geoserver/wms</a>&quot;, {<br>
                                        layers : &#39;naji:TBL_GIS_ARC&#39;<br>
                                });<br>
                wfs = new OpenLayers.Layer.WFS(&quot;WFS&quot;,<br>
                                &quot;<a href="http://localhost:8080/geoserver/wfs" target="_blank">http://localhost:8080/geoserver/wfs</a>&quot;, {<br>
                                        typename : &quot;naji:TBL_GIS_FEATURE_POINT&quot;,<br>
                                        maxfeatures : 1000,<br>
                                        format : OpenLayers.Format.GML.v2<br>
                                });<br>
                wfs.isBaseLayer = true;<br>
<br>
                map.addLayer(layer);<br>
                map.addLayer(wfs);<br>
<br>
                map.addControl(new OpenLayers.Control.LayerSwitcher());<br>
                map.zoomToExtent(bounds);<br>
        }<br>
<br>
Last point: I am using the &quot;full&quot; OL instance and the Geoserver is on the<br>
same machine where the above script is hosted.<br>
<br>
I am completely stuck at this point, and would appreciate any help.<br>
<br>
Thanks,<br>
Majid<br>
<div><div></div><div class="h5"><br>
<br>
<br>
Pedro Baracho wrote:<br>
&gt;<br>
&gt; Could you please copy your code so I can take look?<br>
&gt;<br>
&gt; As I understand, WFS problems are usually related to:<br>
&gt;<br>
&gt; 1- Proxy and Cross Domain Requests<br>
&gt; 2- Projections<br>
&gt; 3- Incorrect OL instancing<br>
&gt;<br>
&gt; As you stated on your email, you are getting correct responses so my guess<br>
&gt; is that you got a problem with Projections.<br>
&gt;<br>
&gt; On Tue, Nov 17, 2009 at 9:18 AM, maimaj &lt;<a href="mailto:maimaj@gmail.com">maimaj@gmail.com</a>&gt; wrote:<br>
&gt;<br>
&gt;&gt;<br>
&gt;&gt; Hi all,<br>
&gt;&gt;<br>
&gt;&gt; I have a WMS layer as my base layer and also a WFS layer on top of it.<br>
&gt;&gt; OpenLayers renders the WMS layer perfectly, but the WFS layer doesn&#39;t<br>
&gt;&gt; show<br>
&gt;&gt; up. I am pretty sure that the OpenLayers is sending an appropriate<br>
&gt;&gt; request<br>
&gt;&gt; to the server (Geoserver) and the server is also responding properly,<br>
&gt;&gt; since:<br>
&gt;&gt;<br>
&gt;&gt;  1. Geoserver is on the same server where my own application (which hosts<br>
&gt;&gt; the OpenLayers.js) is. So<br>
&gt;&gt;      there&#39;s no need for the proxy.<br>
&gt;&gt;  2. Geoserver console logs show that it has received the request<br>
&gt;&gt; properly.<br>
&gt;&gt;  3. When I copy the the request string in the address bar of my web<br>
&gt;&gt; browser, I get the gml2 file from the<br>
&gt;&gt;      server (I also tested the server with uDig as the client, and it can<br>
&gt;&gt; render the features properly through<br>
&gt;&gt;      WFS service provided by Geoserver).<br>
&gt;&gt;<br>
&gt;&gt; Could you please help me on this issue and tell me what might be the<br>
&gt;&gt; cause<br>
&gt;&gt; of this problem? I have copied the init function from the WFS example<br>
&gt;&gt; available in the examples directory of OpenLayers 2.8 and added my own<br>
&gt;&gt; WMS<br>
&gt;&gt; layer, removed the proxy setting, and changed the WFS setting.<br>
&gt;&gt;<br>
&gt;&gt; Thanks in advance,<br>
&gt;&gt; Majid<br>
&gt;&gt;<br>
&gt;&gt; --<br>
&gt;&gt; View this message in context:<br>
&gt;&gt; <a href="http://n2.nabble.com/Problem-with-WFS-tp4017977p4017977.html" target="_blank">http://n2.nabble.com/Problem-with-WFS-tp4017977p4017977.html</a><br>
&gt;&gt; Sent from the OpenLayers Users mailing list archive at Nabble.com.<br>
&gt;&gt; _______________________________________________<br>
&gt;&gt; Users mailing list<br>
&gt;&gt; <a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>
&gt;&gt; <a href="http://openlayers.org/mailman/listinfo/users" target="_blank">http://openlayers.org/mailman/listinfo/users</a><br>
&gt;&gt;<br>
&gt;<br>
&gt; _______________________________________________<br>
&gt; Users mailing list<br>
&gt; <a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>
&gt; <a href="http://openlayers.org/mailman/listinfo/users" target="_blank">http://openlayers.org/mailman/listinfo/users</a><br>
&gt;<br>
&gt;<br>
<br>
</div></div><font color="#888888">--<br>
View this message in context: <a href="http://n2.nabble.com/Problem-with-WFS-tp4017977p4023822.html" target="_blank">http://n2.nabble.com/Problem-with-WFS-tp4017977p4023822.html</a><br>
</font><div><div></div><div class="h5">Sent from the OpenLayers Users mailing list archive at Nabble.com.<br>
_______________________________________________<br>
Users mailing list<br>
<a href="mailto:Users@openlayers.org">Users@openlayers.org</a><br>
<a href="http://openlayers.org/mailman/listinfo/users" target="_blank">http://openlayers.org/mailman/listinfo/users</a><br>
</div></div></blockquote></div><br>