Easy Tutorial
❮ Event Key Keycode Dom Obj Range ❯

Input Color name Attribute

Input Color Object

Example

Get the name of the color picker:


Definition and Usage

Sets or returns the value of the color picker's name attribute.

The name attribute is typically used as an identifier for submitting form data to the server or as a reference identifier in JavaScript on the client side.

Note: Data can only be submitted to the server if the name attribute is set.


Browser Support

All major browsers support the name attribute.

Note: The <input type="color"> element is not supported in Internet Explorer and Safari browsers.


Syntax

Return the name attribute:

Set the name attribute:

Attribute Values

Name Description
name Specifies the name of the color picker

Technical Details

| Return Value: | String, representing the name of the color picker | | --- | --- |


More Examples

Example

Modify the name of the color picker:


Related Articles

HTML Reference: HTML <input> name Attribute


❮ Event Key Keycode Dom Obj Range ❯