I am using jQuery 1.9.1.
Suppose i have a button with id="clickMe" My jQuery code is:
$('#clickMe').click(function(event)
{
eventHandler1();//do something
eventHandler2();//use output from eventHandler1() and do something
}
Now, i want "eventHandler2" to be executed at last so that i could use the output of "eventHandler1". Is there any way to do this manually and not just the way i have put the handlers inside the click event? One more thing, "eventHandler1()" and "eventHandler2()" are present in different .js files and thus the requirement.