Re: Dynamic select lists using optgroups again - without frameworks
- From: RobG <rgqld@xxxxxxxxxxxx>
- Date: Sun, 20 Jan 2008 15:22:41 -0800 (PST)
On Jan 21, 7:42 am, Thomas 'PointedEars' Lahn <PointedE...@xxxxxx>
wrote:
RobG wrote:
It has been mentioned here a number of times that you can achieve the
same effect as a "dom ready" function by inserting all your scripts
just before the closing </body> tab, then calling your initialising
function at the bottom of the last script element, or as the only code
in the last script element.
The DOM will be ready and you don't need to use window.onload (or
document.body or whatever) or DOM ready and it has the pleasant side
effect of loading the page faster.
However, the functionality of this approach is based on mere assumption,
much in contrast to the intrinsic `onload' event handler attribute.
Using onload is also based on the "mere assumption" that the UA
supports onload. If you feature detect for onload and find it's not
supported, what then?
I imagine that scenarios is about as common as finding that the DOM
isn't ready when the very last element is parsed.
--
Rob
.
- Follow-Ups:
- Re: Dynamic select lists using optgroups again - without frameworks
- From: Thomas 'PointedEars' Lahn
- Re: Dynamic select lists using optgroups again - without frameworks
- References:
- Dynamic select lists using optgroups again - without frameworks
- From: Pascal Ehlert
- Re: Dynamic select lists using optgroups again - without frameworks
- From: Pascal Ehlert
- Re: Dynamic select lists using optgroups again - without frameworks
- From: Thomas 'PointedEars' Lahn
- Re: Dynamic select lists using optgroups again - without frameworks
- From: Pascal Ehlert
- Re: Dynamic select lists using optgroups again - without frameworks
- From: RobG
- Re: Dynamic select lists using optgroups again - without frameworks
- From: Thomas 'PointedEars' Lahn
- Dynamic select lists using optgroups again - without frameworks
- Prev by Date: Re: Mootools, ajax and checkboxes
- Next by Date: Re: If you had JavaScript running server-side...?
- Previous by thread: Re: Dynamic select lists using optgroups again - without frameworks
- Next by thread: Re: Dynamic select lists using optgroups again - without frameworks
- Index(es):
Relevant Pages
|