HTML Reference
form
This attribute connects a <textarea> element with a specific form, which thus be-
comes the <textarea> element’s owner. The value of th e form attribute must be
equal to the value of the id attribute of the form. If this attribute is omitted, then the
<textarea> eleme nt must be a descendant o f a <form> e le ment.
rows
The r ows attribute is a non-negative integer specifying the number of text lines for the
control. If this attribute is not spe cified, it defaults to 2.
Example
See the localStorage example on page 281.
C.10 G lobal Attributes
The attributes in this section may be sp ecified on any HTML element.
class
This attribute represents a list of one or more class names separated by spaces. Classes
oer CSS an d JavaScript access to specific HTML elements by means of class selec-
tors or sp ecial functions like the document.getElementsByClassName() method.
id
This attribute defines an id entifier, which must be u nique in the whole document, so
it exclusively identifies an element on which it is u sed. IDs oer CSS and JavaScript
access to specific HTML elements by means of id selectors or spec ia l func tions like
the document.getElementById() method. The id attribute on an <a> e le ment can
also be used to name a URL fragme nt marking an internal hyperlink target loca tion
within a docum ent.
In HTML5, there a re no limits on what form a value of an ID may assume other than
that it must contain at least one character and must not c ontain any space characters.
lang
With this a ttribute, authors specify the language for the content of the element. Its
value must be a valid ISO 639-x/IE TF BCP 47 lan guage code, wh ic h is en for English.
style
This a ttribute allows authors to write inline CSS code.
C.10. Global Attributes 337
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.14.129.194