The Name property of the input tag in HTML

Source: Internet
Author: User

<formAction= "Form_action.asp"Method= "Get">  <P>Name:<inputtype= "text"name= "FullName" /></P>  <P>Email:<inputtype= "text"name= "Email" /></P>  <inputtype= "Submit"value= "Submit" /></form>
Definition and usage

The name attribute specifies the names of the input elements.

The Name property is used to identify the form data that is submitted to the server, or to reference the form data through JavaScript on the client.

Note: Only form elements that have the Name property set can pass their values when the form is submitted

As the example above: at the back end he had an object that existed two properties for FullName and email corresponding to the name attribute in two input.

So we can pass the value to the back end of input.

Note: The value of the name attribute in input must be guaranteed to be consistent with the property name of the backend object before it can be passed.

The Name property of the input tag in HTML

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.