This is basic HTML tutorial

HTML Paragraphs HTML paragraphs are defined with the <p> tag. Example: <p>This is a paragraph.</p> <p>This is another paragraph.</p> HTML Headings HTML headings are defined with the <h1> to <h6> tags. Example: <h1>This is a heading</h1> <h2>This is a heading</h2> <h3>This is a heading</h3> </hr> HTML Links HTML links are defined with the <a> tag. Example: <a href="http://www.w3schools.com">This is a link</a> The example below will open the linked document in a new browser window or a new tab: <a href="http://www.w3schools.com/" target="_blank">Visit W3Schools!</a> An anchor with an id inside an HTML document: Example: <a id="tips">Useful Tips Section</a> Create a link to the "Useful Tips Section" inside the same document: <a href="#tips">Visit the Useful Tips Section</a> Or, create a link to the "Useful Tips Section" from another page: <a href="http://www.w3schools.com/html_links.htm#tips"> Visit the Useful Tips Section</a> HTML Images HTML images are defined with the <img> tag. Example <img src="w3schools.jpg" alt="W3Schools.com" width="104" height="142"> How to use an image as a link. Example: <p>No border around the image, but still a link: <a href="default.asp"> <img style="border:0;" src="smiley.gif" alt="HTML tutorial" width="42" height="42"></a></p> An image-map, with clickable areas: Example: <img src="planets.gif" width="145" height="126" alt="Planets" usemap="#planetmap"> <map name="planetmap"> <area shape="rect" coords="0,0,82,126" href="sun.htm" alt="Sun"> <area shape="circle" coords="90,58,3" href="mercur.htm" alt="Mercury"> <area shape="circle" coords="124,58,8" href="venus.htm" alt="Venus"> </map> An image-map, with clickable areas: Example: <img src="planets.gif" width="145" height="126" alt="Planets" usemap="#planetmap"> <map name="planetmap"> <area shape="rect" coords="0,0,82,126" href="sun.htm" alt="Sun"> <area shape="circle" coords="90,58,3" href="mercur.htm" alt="Mercury"> <area shape="circle" coords="124,58,8" href="venus.htm" alt="Venus"> </map> An HTML Table If you do not specify a border style, the table will be displayed without borders. Headings are defined with the <th> tag instead <td> Example: <table border="1" style="width:300px"> <tr> <td>Jill</td> <td>Smith</td> <td>50</td> </tr> <tr> <td>Eve</td> <td>Jackson</td> <td>94</td> </tr> </table> HTML Unordered/ordered Lists An unordered list starts with the <ul> tag(The ordered with <ol> tag).Each list item starts with the <li> tag. Example: The list items are marked with bullets (typically small black circles). <ul> <li>Coffee</li> <li>Milk</li> </ul> Iframe -An iframe is used to display a web page within a web page. (The URL points to the location of the separate page.) Example: <iframe src="demo_iframe.htm" frameborder="0"></iframe> HTML Javacript Example: <script> document.write("Hello World!") </script> <noscript>Sorry, your browser does not support JavaScript!</noscript> The script below writes Hello World! to the HTML output: <script> document.write("Hello World!") </script> JavaScript can write directly into the HTML output stream: Example: document.write("<p>This is a paragraph</p>"); The HTML charset Attribute To display an HTML page correctly, a web browser must know the character set used in the page. This is specified in the <meta> tag: For HTML4: <meta http-equiv="Content-Type" content="text/html;charset=ISO-8859-1"> For HTML5: <meta charset="UTF-8"> HTML 4 vs HTML 5 In HTML five all tags (even empty elements) must be closed This is correct: A break: <br /> A horizontal rule: <hr /> An image: <img src="happy.gif" alt="Happy face" /> HTML5 Video /Audio- How It Works Example <video width="320" height="240" controls> <source src="movie.mp4" type="video/mp4"> <source src="movie.ogg" type="video/ogg"> Your browser does not support the video tag. </video> To play an audio file in HTML5, this is all you need: Example <audio controls> <source src="horse.ogg" type="audio/ogg"> <source src="horse.mp3" type="audio/mpeg"> Your browser does not support the audio element. </audio> </body> </html>