I have a situation like this one:
talenti = $(".talenti");
filtra = $(".filtra");
wrapNavHeight = $("#wrapNav").outerHeight(true);
filtra.click(function(e) {
e.preventDefault();
$(".nasco").hide();
$("#sliding-navigation").delay(delay).show();
delay += 500;
talenti.removeClass('opened');
filtra.addClass('opened');
filtra.attr('id',"focF");
talenti.attr('id',"");
if (filtra.hasClass("opened")) {
$("#wrapNav").slideToggle("100", "linear", function(){
alert(wrapNavHeight);
$("#container").animate({"height": "+=wrapNavHeight"}, 100,function(){
$(".box").animate({"top": "+=wrapNavHeight"});
});
});
}
});
I am trying to get wrapNavHeight but alert(wrapNavHeight); outputs null; can't then assign that value to the next animate lines
Anyone?