HTML Basic Tags Example

The following is the basic example

<!DOCTYPE html>
<html>
   <head>
      <title>HTML Hello World Example</title>
   </head>
   <body>
      <h1>HTML Hello World Example</h1>
      <p>HTML Content ... </p>
   </body>
</html>

Output :

Comments will not visible in the final output.


HTML Heading Tags Example

The following is the example for heading tags

<!DOCTYPE html>
<html>
   <head>
      <title>HTML Heading Tags Example</title>
   </head>
   <body>
      <h1>here goes heading 1</h1>
      <h2>here goes heading 2</h2>
      <h3>here goes heading 3</h3>
      <h4>here goes heading 4</h4>
      <h5>here goes heading 5</h5>
      <h6>here goes heading 6</h6>
   </body>
</html>

Output :

Comments will not visible in the final output.


HTML Paragraph Tag Example

The following is the example for paragraph tags

<!DOCTYPE html>
<html>
   <head>
      <title>HTML Paragraph Tag Example Title</title>
   </head>
   <body>
      <p>here goes first paragraph of content.</p>
      <p>here goes second paragraph of content.</p>
   </body>
</html>

Output :

Comments will not visible in the final output.


HTML Line Break Tag Example

The following is the example for line break tag (<br/> tag)

<!DOCTYPE html>
<html>
   <head>
      <title>HTML Line Break Example Title</title>
   </head>
   <body>
      <p>Hello there <br />
      Thanks for writing the content<br />
      Thanks<br />
      Alex</p>
   </body>
</html>

Output :

Comments will not visible in the final output.


HTML Preserve Tag Example

The following is the example for preserve tag (<pre/> tag)

<!DOCTYPE html>
<html>
   <head>
      <title>HTML Preserve Formatting Title</title>
   </head>
   <body>
      The following is the sample function code:: <br/><br/>
      <pre>
      public function function_name(){
         alert("Hello There")
      }
      </pre>
   </body>
</html>

Output :

Comments will not visible in the final output.