[jQuery] Re: Using jQuery to see if CSS is disabled.

2009-09-05 Thread Peter Edwards
You could try looping through the document.styleSheets collection and testing the disabled attribute: var styleSheetsDisabled = false; for (var i = 0; i document.styleSheets.length; i++) { if (document.styleSheets.item(i).disabled) { styleSheetsDisabled = true; } } Not sure if this

[jQuery] Re: Using jQuery to see if CSS is disabled.

2009-09-05 Thread ryan.j
off the top of my head, hide an element with css and then get :hidden elements with that id? something like html head script type=text/javascript src=http://www.google.com/jsapi;/script script type=text/javascript google.load(jquery, 1.3.2);

[jQuery] Re: Using jQuery to see if CSS is disabled.

2009-09-05 Thread ryan.j
obviously you'd probably want to set the display attrib in an external CSS file, and if that didn't work you could try to @import some style then check for that.

[jQuery] Re: Using jQuery to see if CSS is disabled.

2009-09-05 Thread ryan.j
although this does raise the question of what happens if css and javascript are disabled. what happens if try{ .. } to set a css attribute with css disabled? On Sep 5, 12:08 pm, ryan.j ryan.joyce...@googlemail.com wrote: obviously you'd probably want to set the display attrib in an external

[jQuery] Re: Using jQuery to see if CSS is disabled.

2009-09-04 Thread Jonathan Vanherpe (T T NV)
mumbojumbo wrote: Hello All, I'm trying to code a site using progressive enhancement methods. It's built upon standards-compliant CSS and HTML and JS. I'm using jQuery on the site to animate some elements on hover etc. Now, when CSS and JS is disabled, it's all good. But, If CSS is disabled