Bug Tracker

Ticket #3587 (closed bug: duplicate)

Opened 7 years ago

Last modified 7 years ago

animate({height: 0}) causes incorrect height after animation is completed

Reported by: TNT Owned by:
Priority: major Milestone: 1.3
Component: effects Version: 1.2.6
Keywords: animate height Cc: TNT, flesler
Blocking: Blocked by:


when i try this:

$('#div4').css({'width': 100, 'height': 100, 'border': '1px solid red'});

$('#div4').animate({height: 0}, 2000);

-> after animation is completed DIV has grow up to 21px height in IE6, in FF DIV have 0px height

<div id="div4"></div>


index.htm Download (993 bytes) - added by TNT 7 years ago.
test html file

Change History

comment:1 Changed 7 years ago by flesler

  • Cc TNT, flesler added
  • need changed from Patch to Test Case

can you make a test case ? (html file)

Changed 7 years ago by TNT

test html file

comment:2 Changed 7 years ago by TNT

I'm added attachment test HTML file

comment:3 Changed 7 years ago by TNT

I'm fixing for me with this code:

$('#div3').animate({'height': '1px'}, 2000, function(){$(this).css({'overflow':'hidden', 'height': '0px', 'visibility': 'hidden'});});

and this working fine (for me). :)

comment:4 Changed 7 years ago by davidserduke

I believe this is a duplicate of #1726. Basically the doctype is malformed so the browser is in quirksmode and jQuery no longer supports quirksmode for animation and the like. Try fixing your doctype and see if that helps too.

comment:5 Changed 7 years ago by davidserduke

  • Status changed from new to closed
  • Resolution set to duplicate
Note: See TracTickets for help on using tickets.