HTML DOM Input Email name attribute
Examples
Get email Field Name:
var x = document.getElementById ( "myEmail") name.;
x The output is: usremail
try it"
Definition and Usage
name attribute is used to set the property value or return email name field.
name attribute is typically used to server identifiers submitted form data, or the client as a Javascript reference identification.
Note: Only the name attribute is set, in the form submission to submit data to the server.
Browser Support
All major browsers support attribute name
Note: Internet Explorer 9 (and earlier versions of IE), or Safari browser does not support type = "email" in the HTML <input> elements.
grammar
Returns the name attribute:
emailObject .name
Setting name attribute:
emailObject .name = name
Property Value
value | description |
---|---|
name | It describes the name of the email field |
technical details
return value: | String representing the name of the email field |
---|
More examples
Examples
Modify the name of the email field:
. Document.getElementById ( "myEmail") name = "newEmailName";
try it"
Related Pages
HTML Reference Manual: HTML <the INPUT> name attribute
Input Email Object