Attributo di azione <form> HTML
Esempio
Al momento dell'invio, invia i dati del modulo a un file chiamato "action_page.php" (per elaborare l'input):
<form
action="/action_page.php"
method="get">
<label for="fname">First name:</label>
<input type="text" id="fname"
name="fname"><br><br>
<label for="lname">Last name:</label>
<input type="text" id="lname" name="lname"><br><br>
<input
type="submit" value="Submit">
</form>
Definizione e utilizzo
L' action
attributo specifica dove inviare i dati del modulo quando viene inviato un modulo.
Supporto browser
Attribute | |||||
---|---|---|---|---|---|
action | Yes | Yes | Yes | Yes | Yes |
Sintassi
<form action="URL">
Valori di attributo
Value | Description |
---|---|
URL | Where to send the form-data when the form is submitted. Possible values:
|
❮ Tag HTML <modulo>