HTML Tutorial
HTML Introduction
HTML is the standard markup language for creating Web pages.
What is HTML?
# html stands for Hyper Text Markup Language
# html is the standard markup language for creating Web pages
# html describes the structure of a Web page
# html consists of a series of elements
# html elements tell the browser how to display the content
# html elements label pieces of content such as "this is a heading", "this is a paragraph", "this is a link", …….
A Simple HTML Document
Example Explained
# The <html> element is the root element of an HTML page
# The <head> element contains meta information about the HTML page
# The <title> element specifies a title for the HTML page (which is shown in the browser's title bar or in the page's tab)
# The <body> element defines the document's body, and is a container for all the visible contents, such as headings, paragraphs, images, hyperlinks, tables, lists, etc.
# The <h1> element defines a large heading
# The <p> element defines a paragraph.
What is an html Element?
An html element is defined by a start tag, some content, and an end tag:
<tag>Content goes here...</tag>
# The html element is everything from the start tag to the end tag.
Note: Some html elements have no content (like the <br> element).
These elements are called empty elements. Empty elements do not have an end tag!
Web Browsers
The purpose of a web browser (Chrome, Edge, Firefox, Safari) is to read HTML documents and display them correctly.
A browser does not display the HTML tags, but uses them to determine how to display the document:
html Page Structure
Below is a visualization of an HTML page structure:
html History
Since the early days of the World Wide Web, there have been many versions of HTML:
HTML Editors
A simple text editor is all you need to learn html.
Learn html Using Notepad or TextEdit
Web pages can be created and modified by using professional HTML editors.
However, for learning html we recommend a simple text editor like Notepad (PC) or TextEdit (Mac).
We believe in that using a simple text editor is a good way to learn HTML.
Follow the steps below to create your first web page with Notepad or TextEdit.
# Step 1: Open Notepad (PC)
Windows 8 or later:
Open the Start Screen (the window symbol at the bottom left on your screen). Type Notepad.
Windows 7 or earlier:
Open Start > Programs > Accessories > Notepad
# Step 2: Write Some html
Write or copy the following HTML code into Notepad:
# Step 3: Save the html Page
Save the file on your computer. Select File > Save as in the Notepad menu.
Name the file "name.htm" or “name.html” and set the encoding to UTF-8 (which is the preferred encoding for HTML files).
# Step 4: View the html Page in Your Browser
Open the saved HTML file in your favorite browser (double click on the file, or right-click - and choose "Open with").
The result will look much like this:







Comments
Post a Comment