I am trying to display a simple inline feature on top of other features with geoserver. I need the top feature to be defined through sld. The sld does'nt give me any error but also does not display the inline feature. What could be wrong in my sld or request?

Here is the sld:

<sld:StyledLayerDescriptor xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                           xmlns:sld="http://www.opengis.net/sld" version="1.0.0">
    <UserStyle xmlns="http://www.opengis.net/sld">
              <CssParameter name="fill">#000000</CssParameter>
              <CssParameter name="stroke">#FFFFFF</CssParameter>
                          <gml:coordinates>-100,50 -90,60 -100,60 -100,50</gml:coordinates>
      <sld:Name>test style</sld:Name>
              <CssParameter name="stroke">#FF0000</CssParameter>
              <CssParameter name="stroke-width">2</CssParameter>

and here is the request (the bounding box parameter changes as I am displaying the data as tiles on google maps):


As a result I see the polygons: enter image description here but not the inline feature that should be a polygon on top of other polygons. Any ideas why?

  • from a quick glance it looks like your entire bbox is within the polygon which is unfilled so there is nothing to see?
    – Ian Turton
    Commented Feb 29, 2016 at 16:41
  • no, this is not the problem. As I mentioned in the question - this was just a url of one tile request - the inline feature does not show up on any of the tiles. For clarification I will change the url and sld in the question
    – P.P.
    Commented Feb 29, 2016 at 16:57

1 Answer 1


Your SLD is stored in the configuration, and you are assuming that you can call it by name.

That's not how it works. User layers can only be used when you are making POST requests for your GetMap, as in the example provided in the GeoServer demo requests.

SLDs stored in the configuration are just sources of UserStyle, everything else gets stripped away.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.