Ben Nolan's non-link element hovering trick for Internet Explorer (that normally only allows :hover styles on links) is pretty handy, but what really impressed me about it is his way of integrating arbitrary Javascript functions into the stylesheet itself:
body { background: url(" javascript: document.body.onload = function(){ ...custom js here... } "); }By specifying a rule like this in the browser's user stylesheet, it might even be possible to run a custom set of Javascript commands on opening of any visited website. (Although my brief attempt at making this work proved unsuccessful.) [via webgraphics]
http://gathering.tweakers.net/forum/list_messages/831654/last
The interesting part is that it is somehow specified in the W3 specs of CSS2, see:
http://www.w3.org/TR/REC-CSS2/generate.html#content
http://www.w3.org/TR/REC-CSS2/media.html
It seems IE is ignoring this directive, which I think is right.