Lets say I have code:
$('#target').click(function() {
alert('Handler for .click() called.');
});
I want that after page is loaded #target would be auto clicked, yet click function remain active.
For example same button for play and stop. This would launch play method but if pressed again would stop that.
Should I just trow it to separate method or if there is single line call for such event?