Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $(document).on('mouseenter touchend','[id*=mmlink]', function (e) {
- var $btn = $(this);
- var href = $btn.attr('href');
- var count = ($btn.data('click_count') || 0) + 1;
- $btn.data('click_count', count);
- if (count == 1) {
- $btn.click(function(v) {
- v.preventDefault();
- });
- } else {
- document.location.href = href;
- }
- });
Add Comment
Please, Sign In to add comment