I\'m using JavaScript to enable/disable stylesheets using the following:
document.styleSheets[0].disabled = true|false;
This JS works fine,
I think in this case you may have to rely on JavaScript.
If you think more down the lines of serving up the style-sheet if needed rather than disabling by default you should nail it.
Why not turning the problem around : only load the CSS if JavaScript is enabled?
Taken from this example, you could use something like:
var fileref=document.createElement("link")
fileref.setAttribute("rel", "stylesheet")
fileref.setAttribute("type", "text/css")
fileref.setAttribute("href", filename)
You can use JavaScript's removeAttribute method for that.
<html>
<head>
<link id="first_style" rel="stylesheet" href="#" disabled />
<script type="text/javascript">
window.onload = function()
{
document.getElementById('first_style').removeAttribute('disabled');
}
</script>
</head>
<body>
<p>something</p>
</body>
</html>