MichDe / wordpress-geo-mashup

Automatically exported from code.google.com/p/wordpress-geo-mashup
1 stars 0 forks source link

try to add maps.stamen.com layer to openLayer #588

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
wp : Version 3.2.1
geo-mashup: Version 1.4.9

Hi all. I am working on my diploma thesis in communication design.

I would like to use Geo Mashup in my project and try to present the maps of the 
maps.stamen.com (toner) . But my skills are only php, css, html, as2, as3 ... 

I installed the Geo Mashup Custom Plugin. I loaded a file called "custom.js" 
(attached). The Script is actually loaded on my live website (closed beta). 
Also the stamen script is loaded. In the worpress plugin i decided to chose the 
OpenLayer. 

So i take the code snippet from Stamen : 

// replace "toner" here with "terrain" or "watercolor"
var layer = new OpenLayers.Layer.Stamen("toner");
var map = new OpenLayers.Map("element_id");
map.addLayer(layer);

And i already contacted Dylan Kuhn an he said he would start something like 
this in there : 

GeoMashup.addAction( 'loadedMap', function( properties, mxn_map ) {

// replace "toner" here with "terrain" or "watercolor"
var layer = new OpenLayers.Layer.Stamen("toner");

// Get the native OpenLayers map from Mapstraction
var map = mxn_map.getMap();

map.addLayer(layer);
} );

----------------------------

But now i got an error ... the error is in this line : 

var layer = new OpenLayers.Layer.Stamen("toner");

something is undefined ... 

Could someone help me ? I just dont know how i can implement those beautiful 
maps for my diploma thesis :( 

Hope someone could help me ;) 

Till Weber

Original issue reported on code.google.com by tillwebe...@gmail.com on 19 Jul 2012 at 6:59

Attachments:

GoogleCodeExporter commented 9 years ago
The mailing is better for help requests - I use issues to track bugs and 
feature requests.

I can tell you that the stamen script is not getting loaded - you can add it by 
customizing the map frame template: 
http://code.google.com/p/wordpress-geo-mashup/wiki/Documentation#Customize_the_i
nfo_window_and_other_content.

Original comment by dylankk...@gmail.com on 25 Jul 2012 at 10:14