<input type="button" value="Button 1" />
<input type="button" value="Button 2" />
<input type="button" value="Button 3" />
and jQuery code snippet:
$(document).ready(function() {
$("[type='button']").each(function(i) {
for (var j = 0; j < i; j++) {
$(this).click(function() {
alert(this.value);
}).slideToggle(300);
}
});
});
What will happend after clicking on button3?
Login in to like
Login in to comment