< OGC Layer Loader

Routing  >

26. WMS Browser Light [plugin]

26.1. Introduction

wmsBrowserLight plugin allows you to add WMS layers to your map using the ogcLayerLoader plugin. Main difference between the wmsBrowerLight and the wmsBroser plugin is the managment of the server list. The plugins manage WMS servers compatible with version 1.1.1 of the OGC WMS spec.. Using the wmsBrowerLight plugin you have three ways to add specify the server end point (url).

  • Simply type in the text box the server you heard about like http://mywmsserverurl.iheard.about (Do not set the version or any other parameters).
  • Define a list of WMS servers using the ini file of the plugin. The servers will be presented to the end user in a list box.
  • Connect to a GeoNetwork node having metadata on WMS services and load server urls from this catalog.

26.2. Plugin Activation

To activate the plugin, load ogcLayerLoader from both CartoClient and CartoServer configuration files and wmsBrowserLight plugins from CartoClient configuration files: client_conf/client.ini and server_conf/"mapId"/"mapId".ini. For instance:

loadPlugins = mapOverlay, ogcLayerLoader, wmsBrowserLight
        

26.3. Define a list of WMS servers using the ini file

To do so, in client_conf/wmsBrowserLight.ini, set the following parameters in the ini file of the plugin.

        catalogtype = ini
        
        servers.0.label = Sandre / Ouvrage
        servers.0.url = http://services.sandre.eaufrance.fr/geo/ouvrage

        servers.1.label = Données administratives et routières en France (Geosignal)
        servers.1.url = http://www.geosignal.org/cgi-bin/wmsmap
    

Warning

If your url contains aditional parameter (..?map=foo), you MUST enclose the url between doublequotes

        servers.1.url = "http://www.foo.org/cgi-bin/mapserv?map=bar"
    

26.4. Connect to a GeoNetwork node having metadata on WMS services

In order to use this type of connection the name of the GeoNetwork node has to be known. Optionnaly, the plugin will first logged into the node if user and password are specified. To do so, in client_conf/wmsBrowserLight.ini, set the following parameters in the ini file of the plugin.

        catalogtype = gn
        gn = http://sandre.eaufrance.fr/geonetwork
        ; unset gnuser and gnpassword if no login has to be made
        gnuser = cartoweb
        gnpassword = cartoweb
        gnlang = en
        ; gnQuery is how CartoWeb could get the list of services in the node
        gnQuery = "category=Services"
    

For the time being, there is no way to query GeoNetwork for services in a consistent manner using the ISO 19115 information. It should be possible to get this information from the tag ScopeCd of the DataQuality section. But this is not a searchable criteria in version 2.0.2. On tip is to create on the GeoNetwork node a category set to "services" and then used this categrory to get the list of server to propose to the end user.

valid xhtml 1.0 valid css