954,593 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

This doesn't work in IE

I've had this problem before, but couldn't get it fixed. I have done a little experiment for an interactive menu using onmouseover and onmouseout. But it only works in Chrome, but I would like it to work in IE as well. Hope you can help.

<!DOCTYPE html>
<html>
<title>Menu Experiment</title>
<head>


</head>

<body>
<p><img src="menu.jpg" alt="Menu Screen" name="mainlogo" usemap="map1"/>

<map name="map1">
<area shape="rect" coords="0,0,120,59" href="main.html" onmouseover="document.mainlogo.src='homemenu.jpg'" onmouseout="document.mainlogo.src='menu.jpg'" />
<area shape="rect" coords="121,0,290,59" href="random.html" onmouseover="document.mainlogo.src='randommenu.jpg'" onmouseout="document.mainlogo.src='menu.jpg'" />
<area shape="rect" coords="122,0,479,59" href="aboutus.html" onmouseover="document.mainlogo.src='aboutusmenu.jpg'" onmouseout="document.mainlogo.src='menu.jpg'" />
</map>
</p>
</body>


</html>
Attachments menu.jpg 26.31KB aboutusmenu.jpg 26.52KB homemenu.jpg 26.58KB randommenu.jpg 26.88KB
penguino138
Junior Poster in Training
68 posts since Mar 2011
Reputation Points: 7
Solved Threads: 0
 

What's it supposed to be doing? Is there a page to actually look at?

Dandello
Posting Whiz in Training
263 posts since May 2010
Reputation Points: 28
Solved Threads: 23
 
What's it supposed to be doing? Is there a page to actually look at?


No. It's a menu experiment. I used onmouseover and onmouseout to create an interactive menu. But it only works in Chrome, not IE

penguino138
Junior Poster in Training
68 posts since Mar 2011
Reputation Points: 7
Solved Threads: 0
 

correct the doctype
html version dependent code fails

would likely be better in css than javascript, a large, and growing larger, proportion of users disable javascript as security risk, javascript menu doesnt work
css menus are much easier to code than image maps,
what happens when the user has the auto resize function (ie>7 ff=all saf=all) & the image is not the size you anticipate & coded for

Yeah I know paranoid, but if you plan for the worst, when **expletive** happens its only a pleasant suprise

almostbob
Posting Sensei
3,149 posts since Jan 2009
Reputation Points: 571
Solved Threads: 376
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: