HTML Elements
HTML Elements includes the paragraph texts, title, the navigation links and all those you see in front of you.
An element consists of three parts:
An opening tag.
The element's content.
A closing tag.
Every web page requires 4 basic elements: the html, head, title, and body elements.
The HTML element
Every webpage begin and end with an HTML tag. Its sole purpose is to encapsulate all the HTML code, so that the web browser can understand it.
Example:
<html>
</html>
Save the above code as index.html. Now open the index.html file in your browser, you will find a blank page.
The HEAD element
The head functions "behind the scenes." Here you can add the elements used for scripting (Javascript), formatting (CSS) and the title.
Example:
<html>
<head>
</head>
</html>
The TITLE element
The title tag is placed within the head element. All those that you write in between the opening and closing <title> </title> tags will be displayed at the top of the browser.
Example:
<html>
<head>
<title>My Website!</title>
</head>
</html>
Save the above code and open it in the browser. You should see "My Website!" in the upper-left, as the window's title.
The BODY element
All your web contents are added here. It includes the Paragraphs, pictures, tables, etc. We will discuss these in detail as the tutorial progress.
Example:
<html>
<head>
<title>My Website!</title>
</head>
<body>
Hello World!
</body>
</html>
Now check out your website!
Related posts:
Your IP address1 is: 172.18.0.2
Tutorials
Latest Updates
Follow us
- Tech-Tutorials twitter.com/techcuriosity