Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to tie events to different parts of an image? 1

Status
Not open for further replies.

royboy75

Programmer
Feb 13, 2007
114
GB
Hello,

I'm not sure if this is the right forumj for that but I'll try...
I have a requirement for our website to embed an image of the globe and when the user hovers on each country he gets some data related to this country pulled out from a DB.
Suppose I already know how to pull the data, I just don't know how to implement an image that can respond to the user's mouse movements, meaning how to embed events inside the image? Any ideas where to start from?

 
Hi Jeff,

Sounds Chinese to me, can you guide me through here please?
 
I've done some googleing and I see what you mean.
Which Javascript event I can tie to the <area> tag?
 
I think you can use the search facility here, the FAQs here... and of course the larger search engines like Google to help yourself. Do a search for: Client side image map

Cheers,
Jeff


[tt]Jeff's Page [!]@[/!] Code Couch
[/tt]

Make sure your web page and css validates properly against the doctype you have chosen - before you attempt to debug a problem!

FAQ216-6094
 
Hmmm... well depending on how you set up your code, you could use the mouseout and mouseover events... one hiding, one showing. Of course you could put the mouseout on the img and have the mouseover on the anchors.

Cheers,
Jeff


[tt]Jeff's Page [!]@[/!] Code Couch
[/tt]

Make sure your web page and css validates properly against the doctype you have chosen - before you attempt to debug a problem!

FAQ216-6094
 
Got it and found a really nice tool to do the job called mapedit. Thanks a lot!
 
MS FrontPage 2003 also has an Image Map editor built in
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top