<div dir="ltr">Thanks Eric, after I removed featureClass, got what I was looking for<br><br>Regards,<br>Indika<br><br><div class="gmail_quote">2008/8/22 Eric Lemoine <span dir="ltr">&lt;<a href="mailto:eric.c2c@gmail.com">eric.c2c@gmail.com</a>&gt;</span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi. If you use externalGraphics do not pass any featureClass to the<br>
WFS constructor. Also check the name of the external graphics prop i<br>
can&#39;t remember if there&#39;s a trailing s or not. Eric<br>
<br>
2008/8/22, Indika Tantrigoda &lt;<a href="mailto:indika85@gmail.com">indika85@gmail.com</a>&gt;:<br>
<div><div></div><div class="Wj3C7c">&gt; Hi all,<br>
&gt;<br>
&gt; I seem to have some trouble with the following<br>
&gt;<br>
&gt; &nbsp; &nbsp; &nbsp;var symbolizer = OpenLayers.Util.applyDefaults(<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; {externalGraphic: &quot;./marker-blue.png&quot;, pointRadius: 20},<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; OpenLayers.Feature.Vector.style[&quot;default&quot;]);<br>
&gt;<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; wfs_test = new OpenLayers.Layer.WFS( &quot;WFS Test&quot;,<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;<a href="http://localhost:8080/geoserver/wfs" target="_blank">http://localhost:8080/geoserver/wfs</a>&quot;,<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {typename: &quot;topp:cities&quot;,<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;maxfeatures: 10<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; },<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {featureClass: OpenLayers.Feature.WFS,<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;styleMap: new OpenLayers.StyleMap({<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;default&quot;: symbolizer<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;})}<br>
&gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; );<br>
&gt;<br>
&gt; I want to replace the default red marker with blue-marker.png<br>
&gt; However I still get the same red marker.<br>
&gt;<br>
&gt; Thanks in advance.<br>
&gt;<br>
&gt; Regards,<br>
&gt; Indika<br>
&gt;<br>
&gt; 2008/8/21 Eric Lemoine &lt;<a href="mailto:eric.c2c@gmail.com">eric.c2c@gmail.com</a>&gt;<br>
&gt;<br>
&gt;&gt; Hi. maxfeatures tells the WFS how many features you want to receive at<br>
&gt;&gt; most. Eric<br>
&gt;&gt;<br>
&gt;&gt; 2008/8/20, Indika Tantrigoda &lt;<a href="mailto:indika85@gmail.com">indika85@gmail.com</a>&gt;:<br>
&gt;&gt; &gt; Hi all,<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; I have managed to display some point data as a WFS layer using<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; &nbsp;wfs_test = new OpenLayers.Layer.WFS( &quot;WFS Test&quot;,<br>
&gt;&gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &quot;<a href="http://localhost:8080/geoserver/wfs" target="_blank">http://localhost:8080/geoserver/wfs</a>&quot;,<br>
&gt;&gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {typename: &quot;topp:cities&quot;,<br>
&gt;&gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;maxfeatures: 10<br>
&gt;&gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; },<br>
&gt;&gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; { featureClass: OpenLayers.Feature.WFS}<br>
&gt;&gt; &gt; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; );<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; The points are displayed as markers similar to the examples.<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; Would there be any way to have a custom marker instead of the<br>
&gt;&gt; &gt; traditional<br>
&gt;&gt; &gt; one ? I plan to have multiple<br>
&gt;&gt; &gt; point layers (as WFS layers) with different markers for each layer.<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; Also what exactly does the maxfeatures: 10 do ?<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; Thanks in advance.<br>
&gt;&gt; &gt;<br>
&gt;&gt; &gt; Regards,<br>
&gt;&gt; &gt; Indika<br>
&gt;&gt; &gt;<br>
&gt;&gt;<br>
&gt;<br>
</div></div></blockquote></div><br></div>