389 posts
  • Has referred 100+ members
  • Has sold $250,000+ on Envato Market
  • Has collected 10+ items on Envato Market
  • Elite Author: Sold more than $75,000 on Envato Market
+5 more
EugeneO says

I have a jQuery animation that works fine in all browsers but does not work as intended in IE7 most probably because of some obscure CSS bug. Is there a way I can allow the script to be included in all browsers except IE7 ?

1799 posts
  • Has referred 1+ members
  • Has sold $5,000+ on Envato Market
  • Has been a beta tester for an Envato feature
  • Has collected 10+ items on Envato Market
+4 more
BroOf says

If you want to include the script in all browser but not in IE 7 you can use this code:

<!--[if ! IE 7]>
Script goes here
<![endif]-->
389 posts
  • Has referred 100+ members
  • Has sold $250,000+ on Envato Market
  • Has collected 10+ items on Envato Market
  • Elite Author: Sold more than $75,000 on Envato Market
+5 more
EugeneO says

I thought IE conditional statements are only seen by Internet Explorer browsers so the example you gave would only include the script in all IE browsers except IE7 .

I manage to fix the problem anyway.

1640 posts Building the Web.
  • Has been a beta tester for an Envato feature
  • Sells items exclusively on Envato Market
  • Has sold $250,000+ on Envato Market
  • Had an item featured on Envato Market
+7 more
ZoomIt says

I manage to fix the problem anyway.

would be nice to also tell how, maybe others would have the same question

3007 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 200+ members
  • Has sold $250,000+ on Envato Market
  • Had an item featured in an Envato Bundle
+7 more
duotive says
Why not use php?

$browser = get_browser();

if($browser->browser == 'IE' && $browser->majorver == 6) {
    echo "IE6";
} elseif($browser->browser == 'IE' && $browser->majorver == 7) {
    echo "IE7";
}


1383 posts
  • Has been part of the Envato Community for over 4 years
  • Has referred 10+ members
  • Has collected 10+ items on Envato Market
  • Sells items exclusively on Envato Market
+1 more
wpCanyonThemes says

Why not use jQuery :P

$.browser

238 posts
  • Has been part of the Envato Community for over 4 years
  • Has collected 1+ items on Envato Market
  • Sells items exclusively on Envato Market
ewizz says

Why use IE?

1148 posts
  • Has referred 1+ members
  • Has sold $1,000+ on Envato Market
  • Has been a beta tester for an Envato feature
  • Has collected 10+ items on Envato Market
+3 more
fillerspace says

I thought IE conditional statements are only seen by Internet Explorer browsers so the example you gave would only include the script in all IE browsers except IE7 .

There are two types of conditional comments: downlevel hidden, and downlevel revealed.

Here is the first type:

<!--[if IE]> HTML <![endif]-->

This is hidden for most browsers because it looks just like a comment, and revealed for IE, since the expression evaluates as true.

Here is the second type

<![if !IE]> HTML <![endif]>

This one is parsed by most browsers because it looks like HTML inside an arbitrary block element. Additionally, if the expression evaluates as true in IE (which this expression won’t), it would also be parsed. In this case, the HTML would be parsed by every browser except IE

389 posts
  • Has referred 100+ members
  • Has sold $250,000+ on Envato Market
  • Has collected 10+ items on Envato Market
  • Elite Author: Sold more than $75,000 on Envato Market
+5 more
EugeneO says

would be nice to also tell how, maybe others would have the same question
I managed to fix the actual problem which was caused by a conflict in z-index values. It was another case of a website rendering flawlessly in every single browser except IE7 . I’m at the stage where if something doesn’t work in IE7 and it isn’t a central piece of the design or function I would rather just rip it out. Luckily I figured this one out pretty soon after posting this thread.
by
by
by
by
by
by