Introduction Of Html

HTML INTRODUCTION:

Hello! Today we Are Lear about HTML.

What is HTML ?

  • HTML stands for hyper text markup language.
  • Html is the creating the web pages.
  • Html describe the structure of a web page.
  • Html consists series  of elements and it can be show the browser how to display the content.

A simple HTML Document

Example:

<!DOCTYPE html>

<html>

<head>

<title>Page Of title</title>

</head>

<body>

<h1>you can write the heading <h1>

<p>you can writes the paragraph</p>

</body>

</html>

Meanings of example:

  • <!DOCTYPE html> Define that this document is an HTML5 document.
  • <html> the root element of an html page.
  • <head> this element contains the meta information about the HTML page.
  • <title> this element display the title for the HTML page(which is shown in the browser’s title bar or page’s tab).
  • <body>defines the documents body and It is a container for all the visible contents like, headings,paragraphs,images,hyperlinks,table,lists etc.
  • <h1>defines the heading a large.
  • <p>defines a paragraph

What is an HTML Element

  • An HTML element is defined by a start tag ,some content and an end tag.
  • <tagname>some contents writes..</tagname>.
  • The HTML element is everything from start tag to end tag.

Example:

<h1>my heading</h1>

<p>my paragraph</p>

 

Empty  HTML Element

Empty Element only start tag not end with close tag.

Example:

<hr> It define the Horizontal line in HTML document.

<br> It define the break line or space given the content.

<img> It define the image in  webpage.

<input> It can be specified user can enter the data.

<link>link tag is used link between  a document and  external resource.

it mainly used link to external style sheets.

<meta>It defines metadata about HTML document. Metadata is information about data.

  • This <meta> tag write inside the <head> element. It can be specified character set, page description, keywords, author of the document, and viewport settings.
  • Metadata is used by browsers because how to display content or reload page, search engines and other web services.

 

HTML Element Types:

Elements can be two types : block level and inline level elements. The document structure block of content can be write.

A block element occupies 100% of the available width and  it is  line break before and after. An inline element will take only space as it needs.

The most commonly used block-level elements are <div> ,<h1> through<h6>,<p>,<form>,<ol>,<ul>,<li>.

And inline-level elements are <a>,<span>,<strong>,<img>,<i>,<b>,<em>,<code>,<input>,<button>.

 

Note: The block-level elements can not be placed within inline-level elements.

For example:<b>hello<p>hello wolrd</p></b> ,this syntax are not allowed.

Nesting HTML Elements:

HTML elements can contain any number of elements(empty elements). Which are used within tags, attributes, and content or other elements.

Example:

<p>Hello World <b>Bold</b></p>

<p>Hello World<em>emphasized</em></p>

<P>Hello World<mark>highlighted</mark></p>

Note: one element inside another element is called nesting. A nested element can also called a child element.

 

 

 

 

 

 

 

 

 

 

 

Leave a Comment