Description
An HTML tag refers to any of the codes used in the HTML language to describe specific elements in a particular webpage, always denoted with <tag (options)>. Commonly used tags are <a> to define hyperlinks, <p> to define paragraphs, <span> to define certain inline elements, and <img> to define images.
Application
An HTML document consists mostly of 1) tags and 2) text elements. Tags define the organization of the HTML, and their appearance can be further be modified with CSS. A typical HTML document uses this basic tag structure:
<html>
<head>
<title>MY TITLE</title>
</head>
<body>
BODY CONTENT HERE
</body></html>
Of course something like a PBwiki rendered HTML document is much more complex, integrating multiple layers of <div> elements in the document body as well as stylesheets, Javascript, and other tags.
HTML Tags and CSS
The relevance of tags to CSS is that the elements modified by your CSS are defined by tags. For example, PBwiki generates the typical SideBar with the following HTML:
<div id="SideBar">
<div class="SideBarTitle">
<a href="/SideBar">SideBar</a>
</div>
YOUR SIDEBAR CONTENT
</div>
As you can see, the <div> tags are further defined by things called id's and a classes. These extra properties allow CSS to find the correct tag to modify. Furthermore, tag structure is hierarchical, so that the SideBar element contains another <div> of class SideBarTitle that contains a <a> link, which ultimately contains the displayed text.
(Note: The SideBar has changed for many wikis. See New SideBar for details.)
Examples
(incomplete)
See Also
Comments (0)
You don't have permission to comment on this page.