View Full Version : Problems with onLoad interference w/ other scripts...

07-27-2006, 02:57 AM
So I am not that hot with programing and just now getting my nose into it. I have used ImageReady/Photoshop to splice a page up. I used ImageReady's rollover image capability because of it's simplicity. However I needed to add a different javascript to add a special rollover effect for a few links. When I try and use both it will not work at the same time. I have gone to the <body tag and removed the onload="preloadImages(); which was put there by ImageReady. When I did this the rollovers made by ImageReady stop working and the new rollovers work. If I add them back in the opposite happens.

This is where I got the javascript for the new rollovers.

The old page can be viewed at www.incandco.com.

I just want to use both at the same time. I am sure this is a very common problem but I have searched all over and can not find anything that can help me. All of the scripting for the old page can be found on the first page and all of the new script is on www.incandco.com. If there is anything else you need to see just holler at me.

Are there any quick fixes that you hXc guys know of, or is there a thread already made that could help me out?

Thanks in advance for any help at all you can provide!

08-23-2006, 03:39 PM
I don't know if you still need help with this, but you can try calling a function in the body onload tag which in turns calls the other functions you need to fire onload. You can list as many functions as you want here and they will all be executed.

<script language="JavaScript">
function windowOnload()

<body onLoad="javascript:windowOnload();">
body content goes here...