[OpenLayers-Users] tile server for custom tiles always needed?

Christopher Schmidt crschmidt at metacarta.com
Thu Aug 7 08:06:28 EDT 2008


On Thu, Aug 07, 2008 at 10:09:32AM +0200, Jens Herrmann wrote:
> Hello,
> I'm a beginner and I want to build a map mit openlayers based on my own 
> custom tiles I rendered with Mapnik. Do I have to set up a tile server 
> for this or is it possible to just give openlayers the path to the tile 
> directory?
> On http://wiki.openstreetmap.org/index.php/OpenLayers_Simple_Example is 
> a short description which says that this can be done with a single line 
> (and some minor modifications):
> 
> var newLayer = new OpenLayers.Layer.OSM("New Layer", "path_to_tiles/", 
> {numZoomLevels: 19});
> 
> Unfortunately this doesnt work here and I could not find any other 
> reference. If this is possible, what would I have to do?

What do you mean by "this doesn't work?" There is no reason it shouldn't
(but be aware that "Layer.OSM" is provided by OpenStreetMap's Javascript
file, and is not included in OpenLayers by default).

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Users mailing list