[Mapserver-users] SLD and multiple NamedLayer
bartvde at xs4all.nl
bartvde at xs4all.nl
Wed Mar 24 03:37:05 PST 2004
Hi list,
is it possible with Mapserver as an SLD WMS to use multiple NamedLayer
elements in the SLD document?
When we use only one NamedLayer with one Rule, everything works fine. When
we use 2 NamedLayer elements, the original map gets drawn. We also tried
copying the LAYER in the MAP file, so that we did not reference the same
NamedLayer twice. This does not make any difference, the layer is rendered
without any Filter/SLD applied.
The reason we want to use this kind of SLD is to have a selection drawn on
top of another selection, and have the result in one image.
Any info appreciated.
<StyledLayerDescriptor version="1.0.0">
<NamedLayer>
<Name>Gemeentes1</Name>
<UserStyle>
<Title>xxx1</Title>
<FeatureTypeStyle>
<Rule>
<Filter>
<PropertyIsEqualTo>
<PropertyName>GEMNAAM</PropertyName>
<Literal>Amsterdam</Literal>
</PropertyIsEqualTo>
</Filter>
<LineSymbolizer>
<Geometry>
<PropertyName>center-line</PropertyName>
</Geometry>
<Stroke>
<CssParameter name="stroke">#ffff00</CssParameter>
<CssParameter name="stroke-width">10.0</CssParameter>
</Stroke>
</LineSymbolizer>
</Rule>
</FeatureTypeStyle>
</UserStyle>
</NamedLayer>
<NamedLayer>
<Name>Gemeentes2</Name>
<UserStyle>
<Title>xxx2</Title>
<FeatureTypeStyle>
<Rule>
<Filter>
<PropertyIsEqualTo>
<PropertyName>GEMNAAM</PropertyName>
<Literal>Amsterdam</Literal>
</PropertyIsEqualTo>
</Filter>
<LineSymbolizer>
<Geometry>
<PropertyName>center-line</PropertyName>
</Geometry>
<Stroke>
<CssParameter name="stroke">#0000ff</CssParameter>
<CssParameter name="stroke-width">2.0</CssParameter>
</Stroke>
</LineSymbolizer>
</Rule>
</FeatureTypeStyle>
</UserStyle>
</NamedLayer>
</StyledLayerDescriptor>
Best regards,
Bart
More information about the MapServer-users
mailing list