\n \n HTML\n JavaScript\n CSS\n Vue\n React\n Python3\n Java\n C\n C++\n C#\n AI\n Go\n SQL\n Linux\n VS Code\n Bootstrap\n Git\n Local Bookmarks\n \n
\n\n \n\n \n
HTML input formmethod Attribute
\nThe formmethod attribute specifies how to send the form-data (the form-data is sent to the page specified in the action attribute).
Valid values:
\n- \n
get- The data from the form will be encoded as part of the URL and sent using HTTP GET method. \n post- The data from the form will be sent using HTTP POST method. \n
Example:
\n<form action="/submit_form.php" method="post">\n <label for="fname">First name:</label><br>\n <input type="text" id="fname" name="fname"><br>\n <input type="submit" value="Submit">\n</form>\n
Note: The default value of the formmethod attribute is get.
YouTip