HTML/Training/Tag syntax
Tag syntax
HTML is using tags for its syntax. A tag is composed with special characters: <, > and /. They are
interpreted by softwares to compose an HTML element.
Decomposition of HTML elements
HTML elements usually come in tag pairs.
For opening a simple element with a start tag
1. it starts with <
2. then a list of characters without space, the tagname (or element)
3. ends usually with a >.
Then closing the simple element with an end tag
1. it starts with </
2. then the same list of characters without space, the tagname (or element)
3. ends usually with a >.
If the tagname is "cite", then you get
<cite></cite>
Some elements do not have an end tag (because they are implied by the following tags). For
example you might have seen:
<br>
An element can have attributes to refine its meaning.