Difference between revisions of "HTML 1"

From FreekiWiki
Jump to navigation Jump to search
m
(Syntax)
Line 25: Line 25:
  
 
== Tags ==
 
== Tags ==
 +
An HTML tag is written with "angle braces" surrounding the element.
 +
<html>
  
 +
As a rule, HTML tags typically come in pairs. The twin, or closing tag, is indicated by a back slash, and the element being closed.
 +
<html></html>
 +
 +
== Self-closing Tags ==
 +
There are exceptions (such as images, horizontal rules, and line breaks), where a second, closing tag would not be appropriate. These are called self-closing tags.
 +
<nowiki><hr /></nowiki>
  
 
== Attributes ==
 
== Attributes ==
== Self-closing Tags ==
+
Once a webpage is complete, there will be many hundreds of elements. We use attributes to add descriptive information to tags. These attributes should be single-spaced apart from each other, have an equal sign, and use double-quotes around the value.
 +
key="value"
 +
 
 +
These attributes need to be added to the first of the tag pairs. This is important, because it's the first element which declares everything. The second tag is just for closing purposes.
 +
<html id="freegeek" lang="en-US"></html>
  
 
= Structure =
 
= Structure =

Revision as of 03:09, 15 November 2013

HTML is the language which drives the entire web. All webpages are created using HTML.

History

What does HTML mean, anyway?

Acronym

The acronym HTML stands for HyperText Markup Language. The very beginnings of HTML is rooted in a Macintosh application known as HyperCard, where one could click "HyperLinks" to other HyperCards. This is the basis for how we interact with webpages today.

Markup

The M in HTML stands for Markup, which means that the actual text in a document (or page) is plainly available -- but it is annotated, or marked-up, to add additional information or instruction on how to display the text.

Language Interpretation

The L in HTML stands for Language, which is an important point. Like spoken language, HTML can be interpreted differently, depending on whom (or, what computer program) is doing the interpretation. This is why webpages can look different in Firefox vs. Internet Explorer.

What's the big deal with HTML 5?

Versions

In the early 1990s, HTML was written with style inline -- things like bold/italic, colors, fonts, backgrounds were written as normal HTML. By 1999, CSS was being more commonly used, and these style elements began to move out of HTML and to CSS. This process is called deprecation; where certain features are still available, but are noted that they'll be removed in o future version.

Standards

HTML is, at it's core, an engineering specification. It is developed, and agreed-upon by representatives from large companies in the industry, such as Microsoft, Apple, Adobe, Google and so on. And HTML 5 isn't a ratified standard yet -- it's only a draft spec.

Syntax

Tags

An HTML tag is written with "angle braces" surrounding the element.

<html>

As a rule, HTML tags typically come in pairs. The twin, or closing tag, is indicated by a back slash, and the element being closed.

<html></html>

Self-closing Tags

There are exceptions (such as images, horizontal rules, and line breaks), where a second, closing tag would not be appropriate. These are called self-closing tags.

<hr />

Attributes

Once a webpage is complete, there will be many hundreds of elements. We use attributes to add descriptive information to tags. These attributes should be single-spaced apart from each other, have an equal sign, and use double-quotes around the value.

key="value"

These attributes need to be added to the first of the tag pairs. This is important, because it's the first element which declares everything. The second tag is just for closing purposes.

<html id="freegeek" lang="en-US"></html>

Structure

Head and Body

Headlines and Paragraphs

Links