What is HTML?





Introduction:


HTML stands for Hypertext Markup Language. We can create pages using HTML. It tells the browser how to display the web page. Unlike programming language that uses scripts to perform the function, HTML uses tags and elements. HTML has been compared to sandwich since it has opening and closing HTML tags. We can use any text editor to run HTML files.

 


boilerplate code of html :


<!doctypt HTML>                          # It tells browser the document type

<html>                                           # It wraps all the content 

<head>                                         # it contain info that shouldn’t be shown to visitors

       <meta character=“utf-8”>      # It consist of most of the characters

  <title>…………</title>                                                                     

</head>      

                                                                                            

<body>                                    # it contain all the info that should be shown to visitor   

</body>                                                                                                   


</html>        


HTML tags and elements :


1)paragraph.

    <p>……</p>


 2)heading

  •  <h1>…..</h1>
  • <h2>.......</h2>
  • <h3>.....</h3>
  • <h4>......</h4>
  • <h5>......</h5>
  • <h6>.....</h6>


 3)Text types:

     *<strong>……</strong>

     *<em>……..</em>

      *<b>……<b>


 4)Orderd list:

    <ol>  

<li>……….</li>

    </ol>


 5)Unorderd list:

    <ul>

<li>………</li>

   </ul>


 6)Comments:

   <!--……………-->


 7)Nested list

    <ol>

       <li>……</li>

       <ul>               

<li>……..</li>

       </ul>  

<li>……..</li>

 </ol>


8)HTML Images:

<Img src” link ” alt=“name of pic” />


 Listed Images:

 <ul>

     <li><<Img src” link ”  alt=“name of pic” /></li>

 </ul>


9)HTML Links :

  •     <a href=“http:/link”>name of topic</a>
  • Images as link: <a href=“http:/link”><img src=“ link”/></a>
  • Email as a link:

    <a href=“mailto:”yourname@yoursite.com></a>


10)Other HTML tags:

•Address:<address>……..</address>


•Article:<article></article>


•Audio:<audio controls>

               <src=“path” type=“audio/mpeg”>

               <src=“path” type=“audio/ogg”>

               </audio>


•<br>:Next line


•Video:

<video controls width=“ ” Height=“ ”>

<src=“path” type=“video/mp4”>

</video>


•Iframe:<iframe src=“ ” width=“ ” height=“ ”></iframe>


•Registration form:

<form method=“post” id=“register” action=“ ”>

<label>……</label>

<input type=“ ” id=“ ” name=“ ” placeholder=“ “>


•Option:

<option>……</option>

 

 



Comments

Popular Posts