[Geoserver-users] Dynamic url's is not working for external graphics in SLD

I red in forum related to this issue topic.Many guys were posting same
issues.
But I can't understant what is the solution for this?
I spend lot of time in this issue.

I am using GeoExt 0.7 and Geoserver 2.2.2.
I created SLD and I applied this sld in my layer.
Layer is showing properly on map but "legend" is not showing on map.
It is throwing "ERROR [lite.StyledShapePainter] - ShapePainter has been
asked to paint a null style!!".
Note:
${Ikon} vaues dynamically getting from WMS layer attribute.
<PointSymbolizer>
    <Graphic>
      <ExternalGraphic>
  <OnlineResource xlink:type="simple"
xlink:href="http://localhost:8080/projName/icons/$\{Ikon\}\.png&quot;/&gt;
  <Format>image/png</Format>
      </ExternalGraphic>
      <Size>16.0</Size>
      <Rotation><ogc:PropertyName>Riktning</ogc:PropertyName></Rotation>
    </Graphic>
</PointSymbolizer>

What I want to do to show the legend on map?

Thanks,
Manog.

--
View this message in context: http://osgeo-org.1560.n6.nabble.com/Dynamic-url-s-is-not-working-for-external-graphics-in-SLD-tp5030286.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

I founded alternate solution for this issue.
I have added static image instead of dynamic images.
In my laver have 5 "Ikon" unique name is there and I have same name images
in local folder.
So I have modified sld like.
<ogc:Filter>
<ogc:PropertyIsEqualTo>
<ogc:PropertyName>Ikon</ogc:PropertyName>
<ogc:Literal>tag_bla</ogc:Literal>
</ogc:PropertyIsEqualTo>
</ogc:Filter>
<PointSymbolizer>
<Graphic>
<ExternalGraphic>
<OnlineResource xmlns:xlink="http://www.w3.org/1999/xlink&quot;
xlink:type="simple"
xlink:href="http://localhost:8080/mgmapper/icons/tag_bla.png&quot;/&gt;
<Format>image/png</Format>.

Same Way I wrote for other values also.
Now I wrote 5 Rule in my sld file.

--
View this message in context: http://osgeo-org.1560.n6.nabble.com/Dynamic-url-s-is-not-working-for-external-graphics-in-SLD-tp5030289p5030835.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

I must be missing something obvious but I just downloaded 2.3-beta1 for Mac. Installed ok but if I double click on the finder I get a message saying "“GeoServer.app” is damaged and can’t be opened. You should move it to the Trash."

If I drop to the command line I can start it and it seems to work OK, I can log onto the control panel etc.

Java is "Apple Inc.: 1.6.0_37 (Java HotSpot(TM) Client VM)"

Anybody any clues what I am missing?

PS I like to nested layer groups, which will make my life a little easier.

Thanks

You can also use dynamic symbolizers for this, which may produce a shorter SLD:

http://docs.geoserver.org/stable/en/user/styling/sld-extensions/pointsymbols.html#dynamic-symbolizers

On Tue, Jan 29, 2013 at 10:31 PM, mano3688 <mano3688@anonymised.com> wrote:

I founded alternate solution for this issue.
I have added static image instead of dynamic images.
In my laver have 5 “Ikon” unique name is there and I have same name images
in local folder.
So I have modified sld like.
ogc:Filter
ogc:PropertyIsEqualTo
ogc:PropertyNameIkon</ogc:PropertyName>
ogc:Literaltag_bla</ogc:Literal>
</ogc:PropertyIsEqualTo>
</ogc:Filter>




image/png.

Same Way I wrote for other values also.
Now I wrote 5 Rule in my sld file.


View this message in context: http://osgeo-org.1560.n6.nabble.com/Dynamic-url-s-is-not-working-for-external-graphics-in-SLD-tp5030289p5030835.html

Sent from the GeoServer - User mailing list archive at Nabble.com.


Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_jan


Geoserver-users mailing list
Geoserver-users@anonymised.comsts.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Hi Manog.

Unfortunately GetLegendGraphic doesn’t support dynamic symbolizers in ExternalGraphic hrefs.
The reason is quite simple: the legend builder doesn’t have access to the Feature data, so it wouldn’t be possible for it to get a concrete value for Ikon attribute to build an existing url for the image.
Your alternative SLD allows the legend to be drawn, because you are using static urls.
Maybe for dynamic symbolizers we should support pre-rendered images, as asked in http://jira.codehaus.org/browse/GEOS-3747.

Mauro Bartolomeoli

==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more information.

Dott. Mauro Bartolomeoli
@mauro_bart
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it


==
Our support, Your Success! Visit http://opensdi.geo-solutions.it for more information.

Dott. Mauro Bartolomeoli
@mauro_bart
Senior Software Engineer

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054 Massarosa (LU)
Italy
phone: +39 0584 962313
fax: +39 0584 1660272

http://www.geo-solutions.it
http://twitter.com/geosolutions_it