sonia
sonia

Reputation: 317

jquery .animate({top: '+=200px}) dont work

I'm having a problem with animate function - my html looks like:

<body>

<div id="blubloc">

<div id="bluhead1">
</div>
<div id="bluhead2">
</div>
<div id="bluhead3">
</div>

</div>


<div id="whitebloc">

<div id="orangediv">
</div>

<div id="rnd">
<img src="img/logo.gif" alt="ROUNDSHOT" />
<a href="" class="button">klik!</a>
</div> 

</div>

blubloc is in front of whitebloc, using z-index. I'm trying to animate whitebloc sliding down, showing more infrmation - I'm using

$('.button').click(function(){
$('#whitebloc').animate({top: '+=200px'});

});

whitebloc is positioned absolute, and divs inside are positioned relative. Animation is not working at all...

Upvotes: 0

Views: 760

Answers (1)

ChristopheCVB
ChristopheCVB

Reputation: 7315

This fiddle is working for me :

http://jsfiddle.net/Christophe/2bQBA/

Upvotes: 2

Related Questions