Since jQuery 1.9, toggleEvent do not exists anymore, so I am trying to do something like: when someone click at .trigger
, the div#map
get bigger, when click again, div#map
get smaller.
$(".trigger").click(function(){
$("#map").animate({height: '400px'}, 550, function() { $(".trigger").text("see small");
});
}, function(){
$("#map").animate({height: '205px'}, 250, function() { $(".trigger").text("see big");
});
});
If I use "toggle" in 1.8.3 it works fine, but I want to run in 1.9.1 and I don't know how.
Example of the code running in 1.8.3: http://jsfiddle.net/EZ9My/