Welcome to WebmasterWorld Guest from 220.127.116.11 , register , free tools , login , search , pro membership , help , library , announcements , recent posts , open posts Become a Pro Member
onLoad Events is this possible stcrim
Is it possible to have two onLoad events on the same page?
And on a related matter - where does someone who knows nothing about js start to learn?
yes it is, I have one like so
I learned js from an o'reilly book called "Dynamic HTML" and pretty much just from doing it.
<added>sorry, I just reread that, you can't have 2 seperate events but you can call multiple functions in the onLoad event.
The one above is even written conditionally through php. ;)
Thank you - that was the ticket!
Will check out o'reilly book called "Dynamic HTML - if there are other suggestions for where to learn js - I am ready to give Amazon a small donation...
That particular book is more of a dictionary where you can look up tags, methods, objects etc. I also have the actual javscript book from o'reilly which is much more in depth. claus
Well, if you are into web-based tutorials and such, there's a nice collection in the G directory:
Sometimes the onload event doesn't fire in IE (at least on my IE). Another option is to stick a script block right before the closing body tag (</body>) and call your function(s) from there.
I've never heard of an onLoad event failing in IE. This makes me wonder if Jordan's page never finishes loading ;-) MonkeeSage
LOL, that could very well be. The last time I tested it my markup wasn't exactly up to par (I don't even think I knew about the validator service then). But even so, the stop button still went gray, so I'm not sure that was it.
I might have also been thinking of strapping the handler in the JS itself, like
document.body.onload = loaded();
, which doesn't seem work in IE at all.
But in any case, I was mistaken about the onload attribute of the body tag, I just tested it a number of times and it has worked every time. :)