Answer & Solution
$('.imgClass').mouseleave(function() {...});
$('.imgClass').mouseleave(function() {...});
How to bind a keyup event handler to all input elements with the class 'inputField' using jQuery?
A). $('.inputField').keyup(function() {...});
B). $('.inputField').addEventListener('keyup', function() {...});
C). $('.inputField').bind('keyup', function() {...});
D). $('.inputField').on('keyup', function() {...});
What jQuery method is used to bind event handlers to elements with specific CSS classes?
A). $('.className').on();
B). $('.className').attach();
C). $('.className').bind();
D). $('.className').delegate();
What jQuery method is used to bind a mouseover event handler to a div element with the id 'myDiv'?
A). $('#myDiv').mouseover(function() {...});
B). $('#myDiv').addEventListener('mouseover', function() {...});
C). $('#myDiv').bind('mouseover', function() {...});
D). $('#myDiv').on('mouseover', function() {...});
Which jQuery method is used to bind event handlers to elements that are currently matching a selector?
A). $(selector).on();
B). $(selector).bind();
C). $(selector).live();
D). $(selector).delegate();
How to capture the x and y coordinates of the mouse pointer when it moves over a div element using jQuery?
A). var x = event.clientX; var y = event.clientY;
B). var x = event.pageX; var y = event.pageY;
C). var x = event.offsetX; var y = event.offsetY;
D). var x = event.screenX; var y = event.screenY;
What jQuery method is used to bind event handlers to elements based on their position within the document?
A). $('#element').hover();
B). $('#element').position();
C). $('#element').scroll();
D). $('#element').offset();
What jQuery method is used to bind event handlers to elements based on their data attributes?
A). $('.element').on('data');
B). $('.element').bind('data');
C). $('.element').delegate('data');
D). $('.element').live('data');
How to bind a keypress event handler to all input elements with the class 'textInput' using jQuery?
A). $('.textInput').on('keypress', function() {...});
B). $('.textInput').addEventListener('keypress', function() {...});
C). $('.textInput').bind('keypress', function() {...});
D). $('.textInput').keypress(function() {...});
Which jQuery method is used to bind event handlers to elements for specific keys on the keyboard?
A). $('#element').keydown();
B). $('#element').keypress();
C). $('#element').keyup();
D). $('#element').on('key', function() {...});
How to attach a click event handler to a button element with the id 'myButton' using jQuery?
A). $('#myButton').on('click', function() {...});
B). $('#myButton').addEventListener('click', function() {...});
C). $('#myButton').bind('click', function() {...});
D). $('#myButton').click(function() {...});