Submit and Reset Inputs
<input type="submit" ... ><input type="reset" ... >
Section titled “<input type="submit" ... ><input type="reset" ... >”An input with type="submit" is displayed as a button in the browser.
When clicked, it triggers the form submission, sending the form data to the location specified in the form’s action attribute.
The value attribute defines the text that appears on the button.
Similarly, an input with type="reset" is displayed as a button that, when clicked, clears all form fields and restores them to their initial values.
<form action="/submit-form" method="post" name="exampleForm"> <label for="username">Username:</label> <input type="text" id="username" name="username" placeholder="Enter your username" required />
<label for="email">Email:</label> <input type="email" id="email" name="email" placeholder="you@example.com" required />
<br /><br />
<input type="submit" value="Submit Form" /> <input type="reset" value="Clear Form" /></form>