I'm using javascript to fix a couple of IE6's horrible CSS deficiencies. Since with what I'm doing I'm already using javascript, it would be nice to just add a function to my current script to deal with this fix and not add a whole new bit in conditional comments. Besides, I'm curious what you think.

So far I've found most people seem to be liking doing
if (!window.XMLHttpRequest) {//IE6- stuff;}
or perhaps a more bullet-proof (or redundant?) version:
if (document.all && !window.opera && !window.XMLHttpRequest) {//IE6 stuff}
But some people seem to think this isn't that great because IE7 users can disable XMLHttpRequest in the program's options. There's also this:
if (typeof document.addEventListener != 'function') {//IE6 stuff}
or I also found someone blogging about this:
if (typeof document.body.style.maxHeight == "undefined")  {//IE6 stuff}

What say you?