Hi guys, thanks for the replies, and sorry for the delay in
responding.
I see that didn't clearly state the context of my problem.
I want to use jQuery to simulate mouse clicks for many different HTML
elements (not just form submit buttons). My test shows that
jQuery.click() doesn't give same
I expected that calling click() on a submit button would trigger a
form's submit handler, but this doesn't seem to be the case.
Example: register a jQuery submit handler:
$('form').submit(function() { alert('jquery submit handler'); });
Then click the corresponding submit button:
Thanks Ariel,
Is there an elegant way to return the
_first_ matching parent of each element in a collection?
Am I missing something obvious?
Yes, it seems I was :-(
$('.clickable').map(function(){
return $(this).parents('.container')[0];
});
That's exactly what I was looking for.
3 matches
Mail list logo