i have these html code:
<body>
<div id="top">
<div id="panels">
<div id="yes">yes</div>
<div id="no">no</div>
</div>
</div>
</body>
I using jQuery (i`m not a specialist) to fadeout old elements and by ajax adding new (ajax code is not ready now)..so the code:
$(document).ready(function(){
jQuery('#yes').click(function(){
$('#panels').fadeOut(1000);
var fun = $('<div>ITS OVER</div>');
$(fun).hide().appendTo('#panels').fadeIn(1500);
});
});
but it works like: i click on the button (#yes) it start to fadeout old elements during this process it fadein new, and when fadeout finish both elements is not displaied, what is the problem? P.S. Sorry for my English