NOTE: Multiple clicks on <a> tag, trigger fires only one time.
<a class="active">One</a>
<a class="active">Two</a>
<a class="active">Three</a>
<div id="count"></div>
<script>
$('a.active').one('click', function() {
$('#count').trigger('click');
});
$('#count').click(function() {
console.log('I Was Clicked Once!');
});
</script>
No comments:
Post a Comment