The internet has changed the way we access information. Before it’s invention books, printed on paper and tightly bound, were your primary source of information. Today any bit of imaginable information rests at your fingertips. In this course you will learn how to create a a beautiful looking website using HTML and CSS. 

Hyper Text Markup Language, gives content structure and meaning by defining that content as, for example, headings, paragraphs, or images.

HTML will always represent content.

Understanding HTML Terms

Elements:

Elements are designators that define the structure and content of objects within a page. Some of the more frequently used elements include multiple levels of headings (identified as <h1> through <h6> elements) and paragraphs (identified as the <p> element); the list goes on to include the <a>, <div>, <span>, <strong>, and <em> elements, and many more.

Elements are identified by the use of less-than and greater-than angle brackets, <>, surrounding the element name.

Attributes:

Attributes are properties used to provide additional information about an element.

The most common attributes are:

Attributes are defined within the opening tag, after an element’s name. Generally attributes include a name and a value. The format for these attributes consists of the attribute name followed by an equals sign and then a quoted attribute value.
eg:

Now that you know what HTML elements, tags, and attributes are, let’s take a look at putting together our first web page.

Setting Up the HTML Document Structure

HTML documents are plain text documents saved with an .html file extension rather than a .txt file extension.
Two of the more popular plain text editors for writing HTML and CSS are Dreamweaver and Sublime Text. Free alternatives also include Notepad++ for Windows and Text Wrangler for Mac.
Important Note:- Microsoft Word or Pages cannot be used as those are rich text editors.

All HTML documents have a required structure that includes the following declaration and elements: <!DOCTYPE html>, <html>, <head>, and <body>.

An Example of a basic HTML structure

 

<!DOCTYPE html>

<html lang=”en”>

<head>

<meta charset=”utf-8″>

<title>Hello World</title>

</head>

<body>

<h1>Hello World</h1>

<p>This is a web page.</p>

</body>

</html>

try the above code in below editor

Self-Closing Elements

Not all elements consist of opening and closing tags. Some elements simply receive their content or behavior from attributes within a single tag. The <meta> element is one of these elements. The content of the previous <meta> element is assigned with the use of the charset attribute and value. Other common self closing elements include:

<br>, <embed>, <hr>, <img>, <input>, <link>, <meta>, <param>, <source>, <wbr>