Andrew McCombe

Full Stack Web Developer

Inspecting jQuery event handlers

Ever had issues finding where a JQuery click handler is defined? Got a project with LOTS of Javascript and can’t find where an event is handled? Here’s how to find out using Google Chrome. 1. Inspect your element. 2. Go to console and enter ‘$($0).data(‘events’);’ ($0 is the current selected element) Expand the object, right […]

Change the cursor with JQuery

Change the cursor with JQuery Occasionally I use JQueryUI components to display dialogs and I like to set the cursor to the ‘timer’ when the event is triggered and back to ‘auto’ afterwards. Here’s how to change the cursor with JQuery. $(‘body’).css(‘cursor’, ‘wait’); To set it back: $(‘body’).css(‘cursor’, ‘auto’); For more information on JQuery’s CSS […]