Attributes are additional information provided by the HTML element.
- HTML elements can set attributes
- Attributes can add additional information to the element
- Attributes are generally described in the Starting Tag
- Attributes always appear as name /value pairs, For example: name = "value" .
The lang Attribute
The report language can be announced in the <html> tag.
The language is pronounced in the lang attribute.
Declaring a language is imperative for openness applications (screen perusers) and inquiry engines
<h1>My First Heading</h1>
<p>My first paragraph.</p>
The title Attribute
HTML passages are characterized with the <p> tag.
In this model, the <p> component has a title characteristic. The estimation of the quality is "About welookups":
welookups is a web engineer's site.
It gives instructional exercises
of web programming,
what is The href Attribute
HTML joins are characterized with the <a> tag. The connection address is indicated in the href attribute
HTML pictures are characterized with the <img> tag.
The filename of the source (src), and the extent of the picture (width what's more, height) are altogether given as attributes:
W3C recommends cites in HTML4, and demands cites for stricter report types like XHTML.
Sometimes it is necessary to utilize cites. This won't show effectively, in light of the fact that it contains a space:
Single or Double Quotes?
single style can utilize however Double style quote are regular HTML
atribute contain twofold quotes,it is important to utilize single statements
HTML attribute commonly refers to attribute value
Attribute values should always be enclosed in quotes.
Double quotes are most commonly used, but single quotes are fine.
Hint: In some individual cases, such as the attribute value itself contains double Quotes, then you must use single quotes, for example: name = 'John "ShotGun" Nelson'
HTML tip: Use lowercase attributes
Attributes and attribute values are not case sensitive.
However, the World Wide Web Consortium recommends lowercase attributes /attribute values in its HTML 4 recommendations.
The new version of (X) HTML requires lowercase attributes.