Thanks again...<br>I have 3 layers, each one has several sublayers.... :<br>OpenLayers.Layer.WMS("Layer1", ...<br>OpenLayers.Layer.WMS("Layer2",<br>OpenLayers.Layer.WMS("Layer3",<br>But my legend only prints one Label ("Layer1") .... None imagens at all... And just for the first layer...<br>
<br> var legendPanel = new GeoExt.LegendPanel({<br> defaults: { <br> style: 'padding:5px' <br> },<br> title: 'Legend',<br> bodyStyle: 'padding:5px',<br>
width: 350,<br> autoScroll: true <br> });<br><br><br>Is there anything else to implement ? Maybe in mapfile?<br><br>Stella<br><br><br><br><div class="gmail_quote">2010/1/6 Andreas Hocevar <span dir="ltr"><<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>></span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="im">On 2010-01-06 18:00, stela anders wrote:<br>
> Yeah! Thats it Andreas!<br>
><br>
> That LegendPanel works with sublayers? I´m a little bit confused right<br>
> now!<br>
<br>
</div>The LegendPanel currently supports one image per layer. GeoServer's<br>
GetLegendGraphic e.g. returns images with symbols and text for all rules<br>
of the SLD that was used to render the layer. I think the same is true<br>
for MapServer, but maybe a MapServer user can give more detail about<br>
what its GetLegendGraphic returns.<br>
<br>
Regards,<br>
Andreas.<br>
<div class="im"><br>
<br>
><br>
> Thanks !<br>
><br>
><br>
><br>
> 2010/1/6 Andreas Hocevar <<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a><br>
</div><div><div></div><div class="h5">> <mailto:<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>>><br>
><br>
> Hi,<br>
><br>
> make sure that your Ext JS build contains Ext.form.Label, or use a<br>
> full<br>
> build. The build that most of the GeoExt exmaples use<br>
> (<a href="http://extjs.cachefly.net/builds/ext-cdn-771.js" target="_blank">http://extjs.cachefly.net/builds/ext-cdn-771.js</a>) does not contain it.<br>
> Look e.g. at<br>
> <a href="http://dev.geoext.org/trunk/geoext/examples/legendpanel.html" target="_blank">http://dev.geoext.org/trunk/geoext/examples/legendpanel.html</a>, it<br>
> uses a<br>
> full build.<br>
><br>
> Regards,<br>
> Andreas.<br>
><br>
> On 2010-01-06 16:24, stela anders wrote:<br>
> > Thanks Andreas !!!!<br>
> > I changed to WMS with success...<br>
> > But now I got that error when trying to generate the legend :<br>
> ><br>
> > Error: Ext.form.Label is not a constructor<br>
> > Arquivo-fonte:<br>
> ><br>
> <a href="http://localhost/Openlayer/Arquivos/geoextx/lib/GeoExt/widgets/LegendPanel.js" target="_blank">http://localhost/Openlayer/Arquivos/geoextx/lib/GeoExt/widgets/LegendPanel.js</a><br>
> > Linha: 293<br>
> ><br>
> > Am I suppossed to change anything?<br>
> ><br>
> > Thanks<br>
> ><br>
> > Stella<br>
> ><br>
> > 2010/1/5 Andreas Hocevar <<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a><br>
> <mailto:<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>><br>
</div></div>> > <mailto:<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a> <mailto:<a href="mailto:ahocevar@opengeo.org">ahocevar@opengeo.org</a>>>><br>
<div><div></div><div class="h5">> ><br>
> > Hi,<br>
> ><br>
> > On 2010-01-04 19:36, stela anders wrote:<br>
> > > Is it possible?<br>
> ><br>
> > You have at least two choices:<br>
> ><br>
> > (1) Use Layer.WMS instead of Layer.MapServer. With minor<br>
> modifications<br>
> > to your mapfile, it is easy to use MapServer as WMS (see<br>
> > <a href="http://mapserver.org/ogc/wms_server.html" target="_blank">http://mapserver.org/ogc/wms_server.html</a>). I think this is<br>
> the best<br>
> > option, because it will build the legend automatically from<br>
> > GetLegendGraphic requests.<br>
> ><br>
> > (2) Use a LayerStore with a legendURL field. For each layer, you<br>
> > have to<br>
> > provide a URL that points to a legend image. This option may<br>
> only work<br>
> > with the current trunk version of GeoExt, not with v0.6.<br>
> ><br>
> > Regards,<br>
> > Andreas.<br>
> ><br>
> > ><br>
> > > I tried to create that :<br>
> > > var legendPanel = new GeoExt.LegendPanel({<br>
> > > title: 'Legend',<br>
> > > dynamic: true<br>
> > > });<br>
> > ><br>
> > > And added to Viewport, but nothing is created...<br>
> > ><br>
> > > Help me please!<br>
> > ><br>
> > ><br>
> > ><br>
> > > _______________________________________________<br>
> > > Users mailing list<br>
> > > <a href="mailto:Users@geoext.org">Users@geoext.org</a> <mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a>><br>
</div></div>> <mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a> <mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a>>><br>
<div class="im">> > > <a href="http://www.geoext.org/cgi-bin/mailman/listinfo/users" target="_blank">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a><br>
> > ><br>
> ><br>
> ><br>
> > --<br>
> > Andreas Hocevar<br>
> > OpenGeo - <a href="http://opengeo.org/" target="_blank">http://opengeo.org/</a><br>
> > Expert service straight from the developers.<br>
> ><br>
> > _______________________________________________<br>
> > Users mailing list<br>
> > <a href="mailto:Users@geoext.org">Users@geoext.org</a> <mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a>><br>
</div>> <mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a> <mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a>>><br>
<div class="im">> > <a href="http://www.geoext.org/cgi-bin/mailman/listinfo/users" target="_blank">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a><br>
> ><br>
> ><br>
> ><br>
> > _______________________________________________<br>
> > Users mailing list<br>
</div><div class="im">> > <a href="mailto:Users@geoext.org">Users@geoext.org</a> <mailto:<a href="mailto:Users@geoext.org">Users@geoext.org</a>><br>
> > <a href="http://www.geoext.org/cgi-bin/mailman/listinfo/users" target="_blank">http://www.geoext.org/cgi-bin/mailman/listinfo/users</a><br>
> ><br>
><br>
><br>
> --<br>
> Andreas Hocevar<br>
> OpenGeo - <a href="http://opengeo.org/" target="_blank">http://opengeo.org/</a><br>
> Expert service straight from the developers.<br>
><br>
><br>
<br>
<br>
</div>--<br>
<div><div></div><div class="h5">Andreas Hocevar<br>
OpenGeo - <a href="http://opengeo.org/" target="_blank">http://opengeo.org/</a><br>
Expert service straight from the developers.<br>
<br>
</div></div></blockquote></div><br>