Note on cartographic client configuration (MapBuilder)

Preamble: This document describes in detail the operations necessary to configure the Mapbuilder cartographic client which is used in the MDweb search and data-entry modules.

This configuration consists of choosing the layers that will appear in the cartographic client and setting their properties.

 

Using the editor 2

How it works. 7

Troubleshooting. 9

 

Configure the cartographic client using the sld editor that is accessible via the administration module  > Geo DB > Configuration > Cartographic editor

 

 

 

The cartographic editor allows you to select, and configure the display of, geographic information layers in the MDweb cartographic client. This operation consists of 3 or 4 steps:

·         Selecting an available information layer

·         Defining its legend (name, background and line colours, type of figuration)

·         Creating and defining layer groups

·         Saving the edited information

 

Step 1: Selecting geographic layers

On first use of the cartographic editor, the Available layers tab is displayed. Use the  icon to select a layer. A dialogue box ‘Name of the group?’ will open with the name Others already filled in. Click OK (the creation of a specific group is covered in step 3). The selected layer will be displayed in the cartographic client.

 

 

 

 

 

Step 2: Editing the geographic layer’s legend

To edit the selected layer’s legend, first click on the Legend tab. To edit your layer’s legend, click on the icon. The style editor will open.

The style editor will allow you to provide the name of the layer which will appear in the legend. For a layer of type polygon, you can choose a background colour (fill colour) and outline colour. For selecting the colours, a palette is available. To validate your modifications, click the ‘Save change’ button before exiting the style editor.

 


 

Managing transparency of layers

The map editor can manage for each layer chosen the transparency of display. For this, you can use the combox box and choose a level of transparency from 0 (entirely transparent) ti 1.0 (any transparency).

 

 

 

 

Remark: All style modifications are applied immediately when you save your changes.

Step 3: Creation of a layer group and adding layers to the group

For a better view of the displayed layers, the cartographic editor allows you to include layers within a layer group. You have to first create a group, then add one or more layers to the group. You can also remove a layer from a group and even delete a whole group.

To create a group, click on the Group tab, enter the name of the group, validate with the Ok and Done buttons.

Subsequently, you can use the Modify group option to add one or more layers to a group or remove a layer from a group. Validate your changes by clicking Done.

 

The result:

Step 4: Saving the changes made during the editing session

Before exiting the cartographic editor, you can save the changes your have made. Do so by clicking on the   icon; a ‘File saved’ message should appear.

 

MDweb’s cartographic editor module creates several types of files necessary for the Mapserver map server and the Mapbuilder client.

When the cartographic editor is invoked for the first time, files mapserver_carto/config/default/carto.map and mapserver_carto/config/default/carto.map.save are created. They are created by reading the geographical database (geometry_columns table) in the config/config.inc.carto.php file. Also created automatically are the context files (with the legend) of the different encountered found in the database. They are created in the mapserver_carto/config/sld/ directory, one xml file per layer.

Finally, during the final saving of your client’s composition, the mapserver_carto/config/default/context.xml file is created. It contains all the information on displaying layers and their properties as they will appear in the cartographic client.

 

Remark: In case you encounter problems in using the cartographic editor, you can delete all these files. When the cartographic editor is next run, it will be as if it is being invoked for the first time and the carto.map and legend files will be recreated.

Reinitilization of map context

 

In the case that you install MDweb on localhost (demonstration version) and that you want to modify the address of web server (production mode) and give a new IP or domain address, the version 1.6 proposes to the administrator to reinitialize the map context to recreate a new files for map context using the new IP or address of your web server.


 

Common errors that can prevent the editor from running (error messages and warnings) can be divided into three major categories:

·         Problem of connecting to the geographic database

·         Write rights for the MDweb directories

·         Inconsistencies in the geographic database

 

The following table can serve as a first troubleshooting guide:

Type of problem

To verify:

Connection to the geographic database

·         The parameters for connecting to the geographic database in the config/config.inc.carto.php file

·         The postgresql user who connects to the database should be the owner of, and have read/write rights for, all the tables

Inconsistencies in the geographic database

·         The geometry_columns table that references the layers of the geometric tables should contain the tables corresponding to your database

·         The srid (spatial reference identifier, i.e., system of projection identifier) used by your information layers should be present in the spatial_ref_sys table

Problem creating configuration files

The Apache user (depending on the system: apache, httpd, etc.) does not have write rights on the MDweb directories. You have to assign these rights. Under linux : chown –R apache:apache mdweb (for example).

  

Contacts

 

 

IRD/ ESPACE unit (US 140)

500, rue Jean François Breton, 34093 Montpellier Cedex 05, France

TEL: +33 (0)4 67 54 87 02

J.C Desconnets jcd@teledetection.fr

 

Site of the MDweb project: www.mdweb-project.org

Online demonstration: demo16.mdweb-project.org