[Openstreetmap-dev] Experiments with AJAX

nick at hogweed.org nick at hogweed.org
Sat Aug 13 22:04:14 BST 2005


Done a bit  of experimenting with AJAX and it seems the following should be 
possible:

1. Draw a polygon (wood, lake, urban area etc) by sketching round its outline 
with the mouse. The polygon outline can then be sent to the database and 
stored via XMLHttpRequest.

2. This will be particularly relevant for Freemap, but might be relevant for 
other projects too: annotate a map with icons to represent hazards such as 
mad cows, floods, giant hogweeds (do a Google search), etc.  The user could 
click the map and add a description of the hazard which can then be put in 
the database. The map would then include that hazard.

3. Roll over an icon e.g. a pub and display information about it as a 
"tooltip", rather like Google does.

Features which will be difficult:

1. Google-style scrolling maps. Only likely to be feasible if the maps are 
purely static rather than being dynamically created from a database; this 
would need, say, nightly regeneration of maps, and storage of proportions 
which probably only someone like Google could manage, not your average 
hosting provider.

2. "Live" drawing on the map e.g. sketching a route as you move the mouse 
along it. Should be possible in SVG though.

Will continue to try stuff out with freemap and update if I come up with 
anything interesting. If anyone is interested in following this I can give 
you a login on Freemap to try it out.

Nick




More information about the dev mailing list