I have a page where I want to implement a DHTML Navigation Bar and a DHTML Countdown Script. Each script works great separately but when both are in the same html file, the first one (nav bar) doesn’t work. Any ideas?
we ll you really haven’t told us enough to help. could you post your code?
You can see what the Nav Bar is supposed to look like at www.team696.org/navhome.html (not all the links in the bar work yet) I took out the countdown to make this work.
comment out the line:
add the lines:
Nifty. Thanks a bundle.
<edit> And I guess because the counter now loads last, the page seems to load faster. Thanks</edit>
And for anyone else who reads this, what happened in this thread was the kind of speedy, quality assistance that every FIRST-er is willing to give. Now THAT, is gracious professionalism.
I haven’t yet looked through your code, but I’d speculate that the problem was that both scripts required a function to be assigned to window.onload so that the function will be called when the browser has finished loading the page. When the second one is assigned to window.onload it overwrites the first one. This is normal browser behaviour and can also be solved by adding an onload element to your body attribute with the two onloads seperated by semicolons:
So there’s another solution. If I diagnosed the problem right. Maybe I’ll actually look a the code if I get time.