Skip to main content

Bug Tracker

Side navigation

#2945 closed bug (worksforme)

Opened May 28, 2008 01:24PM UTC

Closed November 17, 2010 05:07AM UTC

Last modified February 13, 2011 10:41PM UTC

Setting "z-index: auto" in IE6 gives a type mismatch error

Reported by: adrian Owned by:
Priority: low Milestone: 1.4.3
Component: css Version: 1.4.2
Keywords: ie6, z-index Cc:
Blocked by: Blocking:
Description

Html:

<a href="#">click me</a>

Javascript:

$('a').click(
  function () {
   $(this).css({'z-index':'auto'});
   }
);

Onclick the javascript will try to give z-index: auto but in IE6 i receive a type mismatch error (debugger sends me to line 1120 - jquery 1.2.6)

Setting a number instead of "auto" value will work proper and no errors in IE6.

Demo: http://jquerybox.com/jquery/zindex/

Attachments (0)
Change History (7)

Changed May 28, 2008 04:46PM UTC by Markus.Staab comment:1

shouldn't it be

$('a').click(
  function () {
   $(this).css({z-index:'auto'});
   }
);

without the quotes on z-index?

Changed May 28, 2008 04:47PM UTC by Markus.Staab comment:2

oh no, because of the - you need the '. please ignore my post.

Changed May 28, 2008 08:47PM UTC by flesler comment:3

resolution: → invalid
status: newclosed

Changed May 03, 2010 03:36PM UTC by herr.schuessler comment:4

resolution: invalid
status: closedreopened

Changed June 20, 2010 07:03PM UTC by dmethvin comment:5

component: corecss

Changed November 17, 2010 05:07AM UTC by snover comment:6

resolution: → worksforme
status: reopenedclosed

Setting CSS values that IE does not understand no longer throws errors.

Changed February 13, 2011 10:41PM UTC by jitter comment:7

milestone: 1.31.4.3
priority: majorlow
version: 1.2.51.4.2

Fixed since 1.4.3 -> #5509

For a test case see http://bugs.jquery.com/ticket/6525#comment:4