1

Re: Adding layers to maps

Hi,

I would like to add these tow layers to the maps in indcia, like the google maps layer or the bing maps layer:

http://www.geodaten-mv.de/dienste/adv_dop
http://www.geodaten-mv.de/dienste/gdimv_dtk

I think I need to add them to media/js/jquery.indiciaMapPanel.js like it did with an OpenStreetMap Layer. But if I add them like this:

        topoMV : function() { return new OpenLayers.Layer.WMS('MV-Topo', {'http://www.geodaten-mv.de/dienste/gdimv_dtk', {layers: 'gdimv_dtk'}, {'sphericalMercator': true}});}

I just get an empty map. Since they are quite special, for a smal area, I wonder if it would be possible to extend the layer definition to a configuration file, so they don't get overriden by an update. It would be also nice to configure the layers which are used for the maps in indicia in a central config file.

Regards

Daniel

2

Re: Adding layers to maps

Hi Daniel
First thing, you have a syntax error in the JavaScript as there is an extra set of braces. This should be :

        topoMV : function() { return new OpenLayers.Layer.WMS('MV-Topo', 'http://www.geodaten-mv.de/dienste/gdimv_dtk', {layers: 'gdimv_dtk'}, {'sphericalMercator': true});}

It works OK for me with that modification.

Regarding the idea of configuration for this, I like the idea as long as it does not affect performance or complexity. But were you aware there is a layers option you can pass to indiciaMapPanel which can include an array of any WMS or other layers you want to add to the map? So there should be no need to modify the JS file to add this layer.

John van Breda
Biodiverse IT

3

Re: Adding layers to maps

johnvanbreda wrote:

But were you aware there is a layers option you can pass to indiciaMapPanel which can include an array of any WMS or other layers you want to add to the map? So there should be no need to modify the JS file to add this layer.

Yes, but what I wanted is that you can configure the map layers used in the warehouse in a configuration file, so that if I update the warehouse my layers and the setting which one to show is not overwritten.

Regards

Daniel