M M M M M M M M M M M M M M M M
M M M M M M M M M M M M M M M M
M M M M M M M M M M M M M M M M
<html> <body> <h1>This is heading 1</h1> <h2>This is heading 2</h2> <h3>This is heading 3</h3> <h4>This is heading 4</h4> <h5>This is heading 5</h5> <h6>This is heading 6</h6> </body> </html>
Paragraphs
<html> <body> <p>This is a paragraph.</p> <p>This is a paragraph.</p> <p>This is a paragraph.</p> </body> </html> <html> <body>
<p>
This paragraph contains a lot of lines in the source code, but the browser ignores it. </p>
in the source
but the browser ignores it. </p> <p> The number of lines in a paragraph depends on the size of your browser window. If you resize the browser window, the number of lines in this paragraph will change. </p> </body> </html>
Links
<html> <body> <a href="http://www.w3schools.com"> This is a link</a> </body>
</html>
Images
<html> <body> <img src="w3schools.jpg" width="104" height="142" /> </body> </html>
Inserting comments
<html> <body> <!--This comment will not be displayed--> <p>This is a regular paragraph</p> </body> </html>
</body> </html>
Test formating
<html> <body> <p><b>This text is bold</b></p> <p><strong>This text is strong</strong></p> <p><big>This text is big</big></p> <p><em>This text is emphasized</em></p> <p><i>This text is italic</i></p> <p><small>This text is small</small></p> <p>This is<sub> subscript</sub> and <sup>superscript</sup></p> </body> </html>
Pre formating
<html> <body> <pre>
and line breaks. </pre> <p>The pre tag is good for displaying computer code:</p> <pre> for i = 1 to 10 print i next i </pre> </body> </html>
<br /> <p><b>Note:</b> These tags are often used to display computer/programming code.</p> </body> </html>
<p>The title attribute is used to show the spelled-out version when holding the mouse pointer over the acronym or abbreviation.</p>
<p> If your browser supports bi-directional override (bdo), the next line will be written from the right to the left (rtl): </p>
</body> </html> Background colour <html> <body style="background-color:yellow;"> <h2 style="background-color:red;">This is a heading</h2> <p style="background-color:green;">This is a paragraph.</p> </body> </html> Font <html> <body> <h1 style="font-family:verdana;">A heading</h1> <p style="font-family:arial;color:red;font-size:20px;">A paragraph.</p> </body> </html> <html>
<body>
<p> <a href="default.asp">HTML Tutorial</a> This is a link to a page on this website. </p>
<p> <a href="http://www.google.com/">Google</a> This is a link to a website on the World Wide Web. </p>
</body> </html>