Here is the code:
You\'ll notice the alert(document.styl
Try with condition: (IE workaround)
function aftermath(index) {
var css = document.styleSheets[index].rules || document.styleSheets[index].cssRules;
alert(css.length);
}
This is giving the error:
aftermath(document.styleSheets.length - 1);
If i set it to 0 all work fine... The problem is that the css is not ready at this time, if you need to access it, you need to do that in a second moment
Last edit:
If you whant keep css updated from source, you can use a php proxy for loading it:
Then you can get it using e.g. /proxy.php?version=1.7.0&theme=humanity