I am working on a simple web application. To reduce the number of files, I want to put (php) code for the form submission function on the same page as the form. Something like that:
<body>
<form id = "rsvp-status-form" action = "rsvpsubmit" method = "post">
<input type="radio" name="rsvp-radio" value="yes"/> Yes<br/>
<input type="radio" name="ravp-radio" value="no" checked/> No<br/>
<input type="radio" name="rsvp-radio" value="notsure"/> Not Sure<br/>
<input type="submit" value="submit"/>
</form>
</body>
<?php
function rsvpsubmit() {
}
What is the correct way to call a submit function?
source
share