You can access the .data('events') object, which is used to store all the event handler information:
$(document).ready(function() { var $test = $('#test'); $test.bind('click', function() { alert('default handler'); }); var storedClick = $test.data('events').click[0].handler; $test.unbind('click'); $('#restore').click(function() { $test.bind('click', storedClick); }); });
See this in action: http://www.jsfiddle.net/76GPF/
Remember that the events object is occupied by Arrays , so in the real world you have to store full information about the array. I just saved the very first handler in this example.
jAndy source share