HTML Tutorial next Parts
- <p> - opening paragraph tag
- Element Content - paragraph words
- </p> - closing tag
The <html> Element...</html>
<html> begins and ends each and every web page. Its sole purpose is to encapsulate all the HTML code and describe the HTML document to the web browser. Remember to close your HTML documents with the corresponding </html> tag at the bottom of the document.
If you haven't already, open up Notepad or Crimson Editor and have a new, blank document ready to go. Copy the following HTML code into your text editor.
If you opened up your index.html document, you should be starring at your very first blank (white) web page!
The <head> ElementThe <head> element is "next" as they say. As long as it falls somewhere between your <html> tag and your web page content (<body>), you're golden. The head functions "behind the scenes." Tags placed within the head element are not directly displayed by web browsers. We will be placing the <title> element here and we'll talk about the other possible elements in later lessons.
Here's a sample of the initial set up.
<html> <head> </head> </html>
As of yet, we still have nothing happening on the web page. All we have so far is a couple of necessary elements that describe our document to the web browser. Content (stuff you can see) will come later.
The <title> ElementPlace the <title> tag within the <head> element to title your page. The words you write between the opening and closing <title></title> tags will be displayed at the top of a viewer's browser. Here's the html code:
<html> <head> <title>My WebPage!</title> </head> </html>
Name your webpage as you please, just keep in mind, the best titles are brief and descriptive.
The <body> ElementThe <body> element is where all content is placed. (Paragraphs, pictures, tables, etc). As the menu on the left suggests, we will be looking at each of these elements in greater detail as the tutorial progresses. For now, it is only important to understand that the body element will encapsulate all of your webpage's viewable content.
<html> <head> <title>My WebPage!</title> </head> <body> Hello World! All my content goes here! </body> </html>