Am 21.08.2011 01:38, schrieb ddjen11:
stripped down to just this code-

if (document.styleSheets){

     var thecss = new Array();

   var len=document.styleSheets.length;

   for (x=0;x<len;x++)
   {
      alert('sheet '+x+' of '+len);
         if (document.styleSheets[0].rules)
               alert('IE');
      else
            if (document.styleSheets[0].cssRules)
                 alert('FF');
             else
                    alert('unknown');

   }
}


Maybe add curled braces to exclude the error there. Is it allowed to have the semicolon in front of the "else"? (I always added braces so I've never cared about that problem...) Can you access the document.styleSheets[0].disabled property? What value does "len" have? Try also if (document.styleSheets[0]){alert("Exists");}

--
You received this message because you are subscribed to the Google Groups 
"greasemonkey-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/greasemonkey-users?hl=en.

Reply via email to