By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
459,729 Members | 1,398 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 459,729 IT Pros & Developers. It's quick & easy.

JavaScript :hover fix fails when Flash is added to page.

P: 1
My page uses a horizontal navigation bar that requires a JavaScript file to force IE to do hovers. It worked great in both Fire Fox and IE until some Flash code was added.

This is how the Flash was added:

First JavaScript was used to "onload" some files in the body tag. That caused the mouseover fix to fail. I solved that by moving the JavaSript call to the bottom of the page.

Then I added some Flash code and the IE hover fix failed again.

This is as far as I can get.

Any ideas why Flash would abort the JS hover fix?

Flash was added as follows: (script code omitted)

[HTML]<body bgcolor="#7D7653" text="#000000" topmargin="0" onLoad="MM_preloadImages('images/bottommenu/b_bookstore_f2.gif', 'images/bottommenu/b_photogallery_f2.gif', 'images/bottommenu/b_visitus_f2.gif', 'images/bottommenu/b_search_f2.gif')">

<table width="790" border="0" cellspacing="0" cellpadding="0" align="center">
<td valign="top"><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase=",0,0,0" width="790" height="152">
<param name=movie value="images/header.swf">
<param name=quality value=high>
<embed src="images/header.swf" quality=high pluginspage="" type="application/x-shockwave-flash" width="790" height="152">

Thanks, Paul
Oct 1 '06 #1
Share this Question
Share on Google+
1 Reply

Expert Mod 15k+
P: 16,027
If the hover fix code is loaded onload, the body onload will be 'overwriting' it. Use a multiple onload script to run more than one function onload, or just add it to body onload.
May 19 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.