html page code example

Example 1: simple html website coding

<!DOCTYPE html>
<html>
<head>
<style>
body {background="purple";}
</style>
<title>Page Title<title>
</head>
<body>
<h1>Yay</h1>
<p>yay is a word used to describe that your happy!</p>
</body>
</html>

Example 2: basic html document

<!DOCTYPE html>
<html lang="pt-br" xml:lang="fr" xmlns="http://www.w3.org/1999/xhtml">
<head>
	<link rel="stylesheet" type="text/css" href="style.css">
	<title>...</title>
</head>
<body>
	...
<script type="text/javascript" src="script.js"></script>
</body>
</html>

Example 3: html layout

<!DOCTYPE html> <!-- Start of coding page -->
<html> <!-- Start of html coding -->
  <head> <!-- Start of head -->
    <title>TITLE</title> <!-- Title -->
    <script>
      //JavaScript
    </script>
    <style>
      /* CSS */
    </style>
  </head> <!-- End of head -->
  <body> <!-- Start of body -->
    <h1>Hello!</h1>
  </body> <!-- End of body -->
</html> <!-- End of html coding -->

Example 4: basic html codes

<html> </html>
<body> </body>
<h1> </h1>
<br>
<p> </p>
<head> </head>

Example 5: how to layout footer

how to layout footer

Tags:

Misc Example