...

View Full Version : [QUESTION] Zooming in on map



nop01
01-05-2012, 10:53 PM
Hi all,

I have a map of a topographical area divided into districts. On mouseover i'd like the district to light up en when pressing a mousebutton I would like to zoom in, showing only that district... which is divided into teams.

Is that possible with JavaScript? Are there example-script for this purpose?

Hope someone can help.

Nop01

Old Pedant
01-05-2012, 11:10 PM
Various ways to do this. Easiest is to use multiple images that lay one on top of the other. Each one shows just one district. Use GIF or PNG images and have the part of each image that is outside its own district be transparent.

You set the opacity such that they all appear a little dull. Then when the mouse is over one of them, you change its opacity so it appears brighter.

When the mouse is clicked, you simply load in a *NEW* image, which is the zoomed-in image of that district showing the teams. You can just have the zoomed image have a higher z-index than the others so it will appear in front of all of them.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum