How to find the submit button in a specific form in jQuery

Solution 1:

The following should work:

var submit = curElement.closest('form').find(':submit');

Solution 2:

This should work:

var curSubmit = $("input[type=submit]",curForm);

EDIT: Note the missing ' in the selector