Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $('#buttonId').on('click', function () {
- counter = counter + 1;
- console.log('counter--->' + counter);
- if (counter % 3 == 0) {
- // apply new style
- console.log('multiple of 3--->' + counter);
- $('#buttonId').css('background-color', 'red');
- }
- });
Add Comment
Please, Sign In to add comment