" or " formObject.action=URL"."/> " or " formObject.action=URL".">

Home  >  Article  >  Web Front-end  >  What does action mean in html?

What does action mean in html?

WBOY
WBOYOriginal
2021-12-21 09:46:2517322browse

action in html means "submission behavior". The action attribute is used to specify where to send form data when submitting a form. You can also set or return the action attribute of the form. The syntax is "

" or "formObject.action=URL".

What does action mean in html?

The operating environment of this tutorial: Windows 10 system, HTML5 version, Dell G3 computer.

What is the meaning of action in html

In html, acton means the submission behavior, and the action attribute is used to specify when to submit When forming a form, where to send form data,

The syntax is:

<form action=URL>

You can also set or return the action attribute of the form, the syntax is:

formObject.action=URL

The action attribute is defined Where the data is sent when the form is submitted. The example is as follows:

<html>
<head> 
<meta charset="utf-8"> 
<title>123</title> 
</head>
<body>
<form action="demo-form.php">
First name: <input type="text" name="FirstName" value="Mickey"><br>
Last name: <input type="text" name="LastName" value="Mouse"><br>
<input type="submit" value="提交">
</form>
<p>点击"提交"按钮,表单数据将被发送到服务器上的“demo-form.php”。</p>
</body>
</html>

Output result:

What does action mean in html?

Recommended tutorial: "html video tutorial"

The above is the detailed content of What does action mean in html?. For more information, please follow other related articles on the PHP Chinese website!

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn