[Javascript] SAFARI javascript major problem

Troy III Ajnej trojani2000 at hotmail.com
Wed Jul 16 16:54:03 CDT 2008


Hello, Novros.
 
You are replying to a non existing question||problem same time.I already posted the "only how", that shall work in Safari. 
Exactly the one you've just posted...
-But that's worth of about two dead flies.
 
This issue is related to global variable stylesheet coll assignement, 
but as far as this release, it's impossible to achieve in Safari.
 
Not even if you explode it. But all others work as expected.
 
p.s.: your "caveat" remark on "as 1 more thanthe actual"  is incorrect! 
 
But this is some other story...
 
Regards.~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~                                      Troy III                         progressive art enterprise~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 



> Date: Wed, 16 Jul 2008 18:16:17 +0200> From: lester at denhaag.org> To: javascript at lists.evolt.org> Subject: Re: [Javascript] SAFARI javascript major problem> > Troy III Ajnej wrote:> > The complete demo code is here> > [snip snip snip]> > This worx as expected in Firefox 3.0/Linux, Safari 3.1.2/Apple, Opera > 9.51/Linux, xPloders 6, 7 & 8/WinXP:> > ------------------------------- code start -------------------------> > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML> 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">> > <html>> > <head>> <meta http-equiv="content-type"> content="text/html; charset=utf-8">> > <title>Safari Bug</title>> > <link href="test.css"> rel="stylesheet"> type="text/css">> </head>> > <body>> > Not working on Safari!> > <script type="text/javascript">> function rulesLength()> {> var dS = document.styleSheets;> var theRules = dS[0].rules || dS[0].cssRules;> > alert("selector name: " + theRules[0].selectorText);> alert("Rules Length: " + theRules.length);> }> > window.onload = rulesLength;> </script>> > </body>> </html>> > ------------------------------- code end -------------------------> > with the caveat that xPloders 7 & 8 return rulesLength as 1 more than> the actual number of rules in the style sheet.> > Moral of the story: try to avoid running scripts before the page has> loaded completely as much as possible.> > l8R lES> -- > m$' business is scaled and its cost structure is optimized for really,> really big numbers of mindless and fairly undemanding customers.> Robert X. Cringely> http://www.supermarionation.tv> _______________________________________________> Javascript mailing list> Javascript at lists.evolt.org> http://lists.evolt.org/mailman/listinfo/javascript
_________________________________________________________________
Keep your kids safer online with Windows Live Family Safety.
http://www.windowslive.com/family_safety/overview.html?ocid=TXT_TAGLM_WL_family_safety_072008


More information about the Javascript mailing list