Obviously I agree that IE6 should be banned. But since most big
corporations (and clients) still use it, I as a front-end developer
find that we need to keep supporting it.

But indeedly, conditional statements are once again the key.
Add this to the head of your page:
<!--[if ie 6]>
<script>
document.getElementsByTagName("html")[0].className += (" ie6");
</script>
<![endif]-->

This adds the classname .ie6 to the <html> tag. Easy to check for this
in your scripts.
For some sites I use this to set the class .js aswell, so you can do
CSS tricks like .js .hide to hide elements if users have javascript.

Remember to put all the other JS just before the </body> tag so it
won't interfere with the loading of the rest of your document.

.Jorn



On 8 apr, 01:19, tres <treshug...@gmail.com> wrote:
> I think that since user agent and version detection is merely
> deprecated at this point, it would be safe to use it to detectIE6
> given this circumstance, if you absolutely need to. There is no way to
> tell, but by the time it is pulled out of jQuery,IE6will be long
> gone (hopefully).
>
> That being said, conditional comments would probably be the best way
> for a png fix, especially since it doesn't get executed at all in
> other browsers.
>
> I think that all developers should get together and intentionally
> block out all versions of IE. If we all do it, we can stop M$!! BTW,
> anyone see:http://saveie6.com?
>
> --
> Fight the good fight,
> Trey
>
> On Apr 6, 11:18 am, RobG <rg...@iinet.net.au> wrote:
>
> > On Apr 5, 2:43 am, Joe <joseph.is...@gmail.com> wrote:
>
> > > I'm all for migrating to thejQuery.support() utility method, but
> > > there is not definitive test available to detectIE6specifically.  Do
> > > we have a consensus on this yet?
>
> > I think conditional comments are the best way to go, there are a
> > number of solutions.  Don't try sniffing for IE using the UA string.
>
> > <URL:http://groups.google.com/group/comp.lang.javascript/browse_frm/thread...
>
> > --
> > Rob

Reply via email to