d_barszczak Posted October 8, 2007 Share Posted October 8, 2007 Hi all, I have created a form that i would now like to check over with javascript which i think i know how to do but after that has passed i don't know how to submit the form with a javascript command. Link to comment https://forums.phpfreaks.com/topic/72282-form-submission/ Share on other sites More sharing options...
xenophobia Posted October 9, 2007 Share Posted October 9, 2007 For let say you had a form like below: <form name="form_1" action="abc.php" method="post"> </form> So in your js, you use this to post the form: document.form_1.submit(); Link to comment https://forums.phpfreaks.com/topic/72282-form-submission/#findComment-365198 Share on other sites More sharing options...
d_barszczak Posted October 9, 2007 Author Share Posted October 9, 2007 Thank you xenophobia. Is that cross browers compatible? Link to comment https://forums.phpfreaks.com/topic/72282-form-submission/#findComment-365747 Share on other sites More sharing options...
fenway Posted October 10, 2007 Share Posted October 10, 2007 document.forms['form_1].submit() would be. Link to comment https://forums.phpfreaks.com/topic/72282-form-submission/#findComment-366223 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.