Language References
Specifies the URL to which the FORM content is to be sent for processing.
Inline |
<form action = strURL...> |
Script |
form.action = strURL |
strURL |
String specifying the URL to be used. If a relative path is specified, the base URL of the document is assumed. |
The property is read/write with no default value.
The way the data is submitted depends on the value of the method and encoding properties.
In the following example, the URL to which the form is posted ( "http://somesite.com/test" ) is specified after the action attribute.
<form action="http://somesite.com/test" method=POST>
Enter your name: <input name="fname"><br>
Favorite IceCream Flavor...
<select name="flavor">
<option value="Chocolate">Chocolate
<option value="Strawberry">Strawberry
<option value="Vanilla" selected>Vanilla</select>
<p></p>
<input type=submit value="Send">
</form>
In the following example, the URL specified in the action attribute uses the mailto: protocol.
<form action="mailto:sales@widgets.com" method=GET>
<input name=subject type=hidden value="Widget Product Information Request">
Enter your full mailing address<br> <textArea name=body cols=40></textarea>
<input type=submit value="Send Request"
</form>
FORM