34,333
edits
Changes
→Setting Styles using the ''id'' Attribute of an HTML Element
== Setting Styles using the ''id'' Attribute of an HTML Element ==
When defining an HTML tag it is possible to assign that tag an id. For example we might create a heading element with the a ''mainText'' id:
<pre>
<pre>
#mainHeading mainText {color: blue; font-style: normal}
</pre>
Now the tag that has the matching id will inherit the style for that id.