[OpenLayers-Users] Problem with markers
Nick Whitelegg
nick at hogweed.org
Tue Nov 21 17:21:13 EST 2006
Hello everyone,
I'm developing Freemap (www.free-map.org.uk), a "mashup" site which allows
users to annotate OpenStreetMap-based maps. I'm using OpenLayers 2.1/2.2 and
getting some problems with markers which I didn't get when using earlier
versions.
Firstly a problem with markers and OpenLayers 2.1. (2.2 doesn't work at all -
see other email)
If you go to the main page at http://www.free-map.org.uk/npe/, you see a
historical map of the UK overlaid with OSM footpath data plus Freemap's own
annotations layer (the multi-coloured markers).
However, if you move the map around, the markers layer isn't dynamically
loaded as you move into new areas, or if you jump to another location using
the search. For example, if you enter "Brockenhurst" in the search box, the
map relocates to the village of Brockenhurst but a marker in the centre of
the village does not appear. Instead, what happens is it reloads the markers
from the default location (Fernhurst).
Any ideas what might be wrong here? The code to fetch the XML representing the
markers is in:
http://www.free-map.org.uk/javascript/freemaptile.js
with other JS code at:
http://www.free-map.org.uk/javascript/freemaplayer.js
http://www.free-map.org.uk/javascript/main.js
http://www.free-map.org.uk/javascript/npe/init.js (entry point; sets up the
layers)
and the URL of the script serving the XML for the markers (takes a bbox) is:
http://www.free-map.org.uk/common/markers3.php
Any ideas what may be wrong here? Tested on Firefox; the application has
issues with IE at the moment.
Thanks,
Nick
More information about the Users
mailing list