HTML | <input> formaction Attribute
The HTML <input> formaction Attribute is used to specify where to send the data of the form. After submission of the form the formaction attribute called. The form data is to be sent to the server after submission of the form. It overrides the feature of the action attribute of an <form> element.
Syntax:
<input formaction="URL">
Attribute Values: It contains single value URL which is used to specify the URL of the document where the data to be sent after submission of the form.
The possible value of URL are:
- absolute URL: It points to the full address of a page. For example: www.geeksforgeeks.org/data-structure
- relative URL: It is used to point to a file within in a webpage. For Example: gfg.php
Example:
<!DOCTYPE html> <html> <head> <title> HTML <input> formAction Attribute </title> </head> <body style="text-align:center;"> <h1> GeeksForGeeks </h1> <h2> HTML <input> formAction Attribute </h2> <form action="#" method="get" target="_self"> <input type="text" id="Geeks" name="myGeeks" value="geeksforgeeks" formTarget="_blank" formMethod="post" formAction="test.php"> <input type="submit"> </form> </body> </html> |
Output:

Supported Browsers: The browsers supported by HTML | <input> formaction Attribute are listed below:
- Google Chrome
- Internet Explorer
- Firefox
- Apple Safari
- Opera
Recommended Posts:
- HTML | formaction Attribute
- HTML | <button> formaction Attribute
- HTML | DOM Button formAction Property
- HTML | DOM Input Image formAction Property
- HTML | DOM Input Submit formAction Property
- HTML | low Attribute
- HTML | dir Attribute
- HTML | for Attribute
- HTML | min Attribute
- HTML | value Attribute
- HTML | <a> rel Attribute
- HTML | <img> src Attribute
- HTML | <map> name Attribute
- HTML | <li> value Attribute
- HTML | <img> alt Attribute
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.



