Given the following code :
<div class='hotel_photo_select'> Hello </div> <div class='itsHidden' style='display:none'> <div class='hotel_photo_select'> Hello </div> </div>
and
$('.hotel_photo_select').fadeOut(300); $('.itsHidden').show();
I would expect both .hotel_photo_select divs to be hidden. However, the second is not hidden when I show the container.
Is this a jQuery bug? Each item must be hidden after fadeOut ().
The only solution, I think, would be this:
$('.hotel_photo_select').fadeOut(300, function () { $(this).hide(); }); $('.itsHidden').show();
What I find less elegant.
markzzz
source share