> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/
> libs/prototype/"></script>
> <script type="text/javascript">
> Event.observe(window, 'load', function() {
> });
> </script>
> </body>


Why not include prototype and other things in the head section of the
page?  If you use observe it on window load it doesn't haveto byat the
end of the page.

Bythe way, you can also use dom:loaded instead of window load :)
>From API Docs (http://prototypejs.org/api/event/observe) :

"Of course, you'd want this line of code to run once the form exists
in the DOM; but putting inline scripts in the document is pretty
obtrusive, so instead we'll go for a simple approach that waits till
the page is fully loaded:

Event.observe(window, 'load', function() {
  Event.observe('signinForm', 'submit', checkForm);

Just a little wrapping…

Note that if your page is heavy, you might want to run this code
before the page is fully loaded: just wait until the DOM is loaded,
that will be enough. (Prototype's dom:loaded event can help you with
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptaculous@googlegroups.com
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to