[Mapserver-users] WMS style elements and SLD
Rene Teniere
TENIERER at gov.ns.ca
Thu Apr 15 13:23:07 PDT 2004
Thanks, that would be why it is so confusing. Keep thinking that
everything in the OGC reference has been implemented in MapServer
(duh!). I have been looking at the reference you suggested and have
found it helpful. I have just performed a GetMap request to test it, and
the style did not come through. Do I have to remove the style element in
the mapfile in order for it to work?
Rene
>>> Yewondwossen Assefa <assefa at dmsolutions.ca> 2004-04-15 4:44:18 PM
>>>
The NamedStyle is not supported in mapserver currently. (Only User
defined styles are supported) It refers to a possiblity to draw a layer
using a predfined name. For example the same road data can be drawn
using a style called "theamtic" for tourist maps or "Regular" for
another type of maps. In mapserver world, It would mean having one(or
several) classes defining the thematic style, and one (or several)
classes for the Regular style. The styles would me butally exclusive.
The user can then selects through the sld which style to use for
drawing
tha layer. This does not yet exists in Mapserver.
Using wms_sld_url should be enough for using the sld with a server.
You can also refer to
http://mapserver.gis.umn.edu/cgi-bin/wiki.pl?SLDMapServer for more
infos.
Later,
Rene Teniere wrote:
> Assefa,
>
> Thanks, It's all so confusing. I have seen so many variations on how
to
> do this, and am especially wondering what the NamedStyle refers to.
Does
> it use the style element in the mapfile, or does it have to be
created?
> In the OGC SLD reference it shows the NamedLayer, and NamedStyle, but
I
> do not know where the NamedStyle comes from or how it is created. If
I
> use wms_sld_url, do I still have to use wms_style or wms_stylelist?
As
> you can see I have a lot of questions and I'm sorry for the volume as
I
> know SLD is new to MapServer.
>
> Rene
>
>
>>>>Yewondwossen Assefa <assefa at dmsolutions.ca> 2004-04-15 2:21:52 PM
>>>>
>
> Rene,
>
> You should use the wms_sld_url metadata. So in your case you would
> have "wms_sld_url" "http://10.2.185.9/wms/basewms_sld.xml".
> Note also that there is the wms_sld_body metedata that can be set
to
>
> the actual contect of the sld document.
>
> Best Regards,
>
--
----------------------------------------------------------------
Assefa Yewondwossen
Software Analyst
Email: assefa at dmsolutions.ca
http://www.dmsolutions.ca/
Phone: (613) 565-5056 (ext 14)
Fax: (613) 565-0925
----------------------------------------------------------------
More information about the MapServer-users
mailing list