[Javascript] Questions about document.readyState

Nick Fitzsimons nick at nickfitz.co.uk
Sun Jun 25 12:21:52 CDT 2006


tedd wrote:
> At 3:43 PM +0100 6/25/06, Nick Fitzsimons wrote:
>> Note that it's a non-standard property, so non-Microsoft browsers are under no obligation to support it, or to have it work the same way. The above code shows different results in Internet Explorer for Windows (v. 6) and Opera (v. 8.5), but shows no result at all in Firefox 1.5.
> 
> Nick:
> 
> If "readyState" is the non-standard property, what's the equivalent "standard" property?
> 
> In other words, how do you do the same thing in other browsers? I want to know when the other browsers are done doing whatever they do so I can send them a command.
> 
> This is sounding a bit like ajax, is it along the same lines?
> 
> Thanks.
> 
> tedd
> 

If you're looking for something that tells you when the document is 
completely parsed, but not yet ready to fire the onload event because 
(for example) it's still downloading graphics, then you're in luck, 
because some of the best JS coders in the world have been collaborating 
on solving this problem. Have a look at:

<http://dean.edwards.name/weblog/2006/06/again/>

and be sure to check out the comments, as there are a lot of links to 
places where people have incorporated the code into libraries and so forth.

HTH,

Nick.
-- 
Nick Fitzsimons
http://www.nickfitz.co.uk/





More information about the Javascript mailing list