the attached patch ports TMS baselayer functionality from the D6 to D7 version of openlayers.

works so far for me in combination with tilemill and tilestream but i encountered the issue:
i have an MBTiles export for zoom levels 0-8. everything works fine for zoom levels 0-4. but then openlayers seems to generate wrong image links like the following:
http://localhost:8888/1.0.0/my_map/-1/18/20.png

as tmcw stated in the #mapbox irc channel there seems to be some PHP number conversion problem in D7 but we couldn't really figure out how exactly that's being caused...

CommentFileSizeAuthor
openlayers_tms_baselayer.patch1.86 KBdasjo

Comments

dasjo’s picture

i just wanted to clarify that the problem is with the zoom-level part of the image links being generated:
...8/1.0.0/my_map/-1/18/20.png

here -1 indicates an invalid zoom level which should be a positive number.
as stated above the issue only appears for zoom levels greater than 4.

zzolo’s picture

Status: Needs review » Fixed

Thanks @dasjo. Comitted:
http://drupalcode.org/project/openlayers.git/commit/6f50436

do you mind creating a new issue for the zoom level stuff.

dasjo’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.