HTML textarea Tag name Attribute Tutorial

In this section, we will learn what the name attribute is and how to use it.

What is name Attribute in HTML <textarea> Tag?

The name attribute used in HTML <textarea> element to create a name for the target textarea.

This name can then be used in other languages like JavaScript to access the target <textarea> element and apply any sort of modifications to that element programmatically.

Also, in servers, the value of the name attribute helps to access the value of a <textarea> element if needed.

HTML name Attribute in <textarea> Tag Syntax:

<textarea name = “name”> </textarea>

<textarea> Tag name Attribute Values

The value we set for the `name` attribute could be any general or specific name. But usually it’s a good idea to set a name that reminds you of what textarea element this name is referring to.

Example: using name attribute in HTML <textarea> tag

See the Pen using name attribute in HTML <textarea> tag by Omid Dehghan (@odehghan) on CodePen.

Facebook
Twitter
Pinterest
LinkedIn

Top Technologies