Hi Fabrice
I have SVG files in the Geoserver data_dir\workspaces\<workspacename>\styles\ folder.
These are referenced in the SLD like this:
--- Snip ---
<ExternalGraphic>
<OnlineResource
xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:type="simple"
xlink:href="osmmsymbols/manmadeLandformPattern.svg"/>
<Format>image/svg+xml</Format>
</ExternalGraphic>
--- Snip ---
Full example:
<FeatureTypeStyle>
<Rule>
<Name>Slope (pattern) - 1:35 to 1:4,500</Name>
<ogc:Filter>
<ogc:Or>
<ogc:PropertyIsEqualTo>
<ogc:PropertyName>osmmstyle_name</ogc:PropertyName>
<ogc:Literal>slopeFill</ogc:Literal>
</ogc:PropertyIsEqualTo>
<ogc:PropertyIsEqualTo>
<ogc:PropertyName>osmmstyle_name</ogc:PropertyName>
<ogc:Literal>slopeHistoricFill</ogc:Literal>
</ogc:PropertyIsEqualTo>
</ogc:Or>
</ogc:Filter>
<MinScaleDenominator>35</MinScaleDenominator>
<MaxScaleDenominator>4500</MaxScaleDenominator>
<PolygonSymbolizer uom="http://www.opengeospatial.org/se/units/metre">
<Fill>
<GraphicFill>
<Graphic>
<ExternalGraphic>
<OnlineResource
xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:type="simple"
xlink:href="osmmsymbols/manmadeLandformPattern.svg"/>
<Format>image/svg+xml</Format>
</ExternalGraphic>
<Size>24</Size>
<Rotation>0</Rotation>
</Graphic>
</GraphicFill>
</Fill>
</PolygonSymbolizer>
</Rule>
</FeatureTypeStyle>
Ross
-----Original Message-----
From: ibFabrice [mailto:irie.fabrice@anonymised.com]
Sent: 14 August 2014 21:31
To: geoserver-users@lists.sourceforge.net
Subject: [Geoserver-users] Upload SLD + SVG File
Hi everyone,
I use Geoserver version 2.5.2
I want to add my custom SLD With the svg in my geoserver. When i try to validate my SLD i get this message :
Parsing failed for ExternalGraphic: java.lang.IllegalArgumentException: URI is not absolute.
In the log file i get this message :
2014-08-13 09:07:29,901 WARN [geotools.styling] - can't parse BOULANGERIE.svg as a java resource present in the classpath
Where can i put this file (svg) in my server ? How to configure the classpath ?
Best regards,
Fabrice
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/Upload-SLD-SVG-File-tp5156474.html
Sent from the GeoServer - User mailing list archive at Nabble.com.
------------------------------------------------------------------------------
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users
This message is strictly confidential. If you have received this in error, please inform the sender and remove it from your system. If received in error you may not copy, print, forward or use it or any attachment in any way. This message is not capable of creating a legal contract or a binding representation and does not represent the views of Angus Council. Emails may be monitored for security and network management reasons. Messages containing inappropriate content may be intercepted. Angus Council does not accept any liability for any harm that may be caused to the recipient system or data on it by this message or any attachment.