Skip to content

Instantly share code, notes, and snippets.

@adamlogic
Created November 20, 2008 15:10
Show Gist options
  • Save adamlogic/27060 to your computer and use it in GitHub Desktop.
Save adamlogic/27060 to your computer and use it in GitHub Desktop.
submitClick: function() {
return this.click(function() {
var el = $(this);
if (el.attr('target')) {
el.findTarget().submit();
} else {
el.parents('form:first').submit();
}
return false;
});
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment