I have this script that on click fades an element, changes css and unfades it. I want that on the second click it would do the same but change to some other css. I want it to do this in a some kind of loop. And also can I make this in less code? Sorry if it's an easy question, I'm new at js.
<script>
$(function() {
$("#banner").click(function() {
$("#banner").fadeOut("fast", function() {
$("#banner").css({top:"0", left:"0"});
}).fadeIn("slow");
});
});
</script>