Tuesday, March 23, 2021

HTML Elements | HTML Tags



HTML Elements


HTML documents are made up by HTML elements. HTML elements are written with a start tag <> and a end tag </> and Some content in between two tags, But Some HTML elements do not have an end tag Such As <br> Tags, HTML elements with no content are called empty elements.
So Here is an empty element without a closing tag the <br> tag . the <br> tag defines a line break.
Start Tag Element Content End Tag
<h1> My First Heading </h1>
<p> My First Paragraph </p>
<br>
<hr>

Is HTML tags are case sensitive ?
HTML tags are not case sensitive: <p> means the same as </p>



HTML Horizontal Rules



The <hr> tag creates a horizontal line in an HTML page.
The <hr> element can be used to separate content:


HTML CODE EXAMPLE : HTML <hr> Tags



HTML Line Breaks


The HTML br element defines a line break. You can use br tag for line break or new line without starting a new paragraph

HTML CODE EXAMPLE : HTML <br> Tags




The <br> element is an empty HTML element. It has no end tag.



The HTML Head Element



The HTML <head> element has nothing to do with HTML headings.
The HTML   <head> element contains meta data. Meta data are not displayed.
The HTML <head> element is placed between the <html> tag and the <body> tag:


HTML CODE EXAMPLE : Head Element | Meta Data


The HTML <title> Element



The HTML <title> element is meta data. It defines the HTML document's title.
The title will not be displayed in the document, but might be displayed in the browser tab.

The HTML <meta> Element



The HTML <meta> element is also meta data.
It can be used to define the character set, and other information about the HTML document.

More Meta Elements
In the chapter about HTML styles you discover more meta elements:
The HTML <style> element is used to define internal CSS style sheets.
The HTML <link> element is used to define external CSS style sheets.

HTML Tip - How to View HTML Source
For Display The HTML Source Code of a page at first Open This page by a web Browser and Press Ctrl+U