Created
May 31, 2012 22:30
-
-
Save b3457m0d3/2846787 to your computer and use it in GitHub Desktop.
submit modal form in bootstrap
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$('.modal-form-submit').on('click', function(e){ | |
// We don't want this to act as a link so cancel the link action | |
e.preventDefault(); | |
//grad id of form to submit from rel attr | |
var id = $(this).attr('rel'); | |
// Find form and submit it | |
$('#'+id).submit(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment