I am working with a colleague in a different department right now. His department provides a bit of html in an iframe that contains a link to a style sheet. However, I wanted him to remove the link so that I could change the style sheet based on a users cookie. The differences are pretty drastic so I was thinking that it is best to use JS to pick between two separate CSS files. This other person mentioned something about making the CSS file "intelligent" and show the appropriate styles based on the cookie. Is there a way to determine what cookie a user has and have one style sheet display different styles? Not to my knowledge but I just wanted to through it out there.
Not sure if this is exactly what you were after but you could read a cookie then place a class in the body tag dynamically depending on the cookie value. Then you could set up different styles based on the class in the body tag etc.
e.g.
body.no-warning h1{color:green}
body.warning h1 {color:red}
Bookmarks