HTML and CSS Reference
In-Depth Information
Chapter 2
HTML and CSS Basics
HTML5 is the latest and greatest, and is still taking shape as we write. But it's flexible and forward-looking
by design, and most of HTML5 is ready to use right now. This topic will show you how. Chapter 1 briefly
introduced you to HTML and CSS, and in this chapter we'll go a bit deeper and show you how you can
write markup and style sheets to create your own web pages. You'll become familiar with the fundamental
components of HTML and how to use them. As you know by now, you must adhere to some standards
when constructing a document for the Web, and we're going to be writing lean, valid, semantically rich
HTML5 throughout the chapters to come.
Later in the chapter, we'll walk you through the essentials of CSS so you can use it to visually style your
web pages. HTML provides the structure that supports the content of your web pages, whereas CSS adds
some polish to make your content more attractive and memorable. Designing websites with CSS isn't
possible without some solid bedrock of markup underneath, so let's begin at the beginning.
The Parts of Markup: Tags, Elements, and Attributes
The linchpin of HTML is the tag . Tags are the coded symbols that separate and distinguish one portion of
content from another while also informing the browser about what type of content it's dealing with. A web
browser (or any user-agent) can interpret the tags embedded in an HTML document and treat different
types of content appropriately. Most of the tags available in HTML have names that describe exactly what
they do and what sort of content they designate, such as headings, paragraphs, lists, images, quotations,
and so on.
Search WWH ::

Custom Search