RaysWebClass.Com |
One
Two
Three
Hyperlink prefix: | Service | Example |
---|---|---|
Local Link to another page | <a href='page2.html'> Page 2 </a> | |
http:// | External link to another web site | <a href='http://www.yahoo.com'> Yahoo </a> |
file:// | Download a file | <a href='file://widget.zip'> Widget </a> |
mailto: | Link an Email | <a href='mailto:rlepine@lsu.edu?subject=Web Email'>Email Me</a> |
Now let's use these tags to put together our home page.
- Open the HTMLClass folder.
- Right click on test.html, choose copy.
- Right anywhere and choose past.
- Right click on test - Copy.html and choose rename.
- Rename the file to index.html.
NOTE: index.html is the default or home page name.
e.g.: when you open a web site that has many pages in it and you do not spesify which page you want opened, the default page (index.html) will open. This is why index.html is referred to as the Home page.- Now, double click index.html. It will open in the browser.
- Right click in the browser and choose view source.
- Replace all the code with this:
<!DOCTYPE html>
<html lang='en'>
<head>
<meta charset='utf-8'>
<title>Global Company - Home</title>
</head>
<body bgcolor='gray' align='center'>
<font size='3' face='verdana'>
<table border='1' cellspacing='0' width='800'
align='center' bgcolor='white'>
<tr>
<td colspan='2' bgcolor='#2E869D' height='50'>
HEADER
</td>
</tr>
<tr valign='top'>
<td width='110'>
MENU
</td>
<td height='1000'>
MAIN PAGE
</tr>
<tr>
<td colspan='2' height='17' align='center'>
FOOTER
</td>
</tr>
</table>
</font>
</body>
</html>
- Save index.html. Refresh the browser to see the changes.
- Add content:
(If these images are not already in the images folder,
copy them and paste them into your images folder.)
NOTE: You may have to remove the [1] from the name of the copied images.
For example, Globe.gif may copy over to the images folder as Globe[1].gif
In the header container, replace the word Header with this code:<!-- * * * * * * -->
<!-- * Header * -->
<!-- * * * * * * -->
<h2> Global Company
<img src='images/Globe.gif' align='middle'></h2>
In the nav container, replace Menu with:<!-- * * * * * * * * * * -->
<!-- * Navigation Menu * -->
<!-- * * * * * * * * * * -->
<br>
<a href='index.html'>Home</a>
<br><br>
<a href='History.html'>History</a>
<br><br>
<a href='Products.html'>Products</a>
<br><br>
<a href='Contact.html'>Contact Us</a>
<br><br>
In the section container, replace Main Body with:<!-- * * * * * * * * * * * * * -->
<!-- * Main Page: BELOW Here * -->
<!-- * * * * * * * * * * * * * -->
<img src='images/GlobalCompany.png' align='left'>
<h1><font color='#2E869D'>
Global Company
</font></h1>
<br><br><br><br><br>
<img src='images/Gadget.gif'>
<img src='images/Widget.gif'>
<br clear='all'><br>
Welcome to Global Company, the company that manufactured no less than two products!
Read the <a href='History.html'>history</a> of our great company and see our
<a href='Products.html'>products</a>.
<!-- * * * * * * * * * * * * * -->
<!-- * Main Page: ABOVE Here * -->
<!-- * * * * * * * * * * * * * -->
In the footer container, replace Footer with:<!-- * * * * * * -->
<!-- * Footer * -->
<!-- * * * * * * -->
<small>
Copyright ©
<!-- * * * * * * * * * * * * * -->
<!-- * Displays Current Year * -->
<!-- * * * * * * * * * * * * * -->
<script type="text/javascript">
var theDate=new Date()
document.write(theDate.getFullYear())
</script>
Global Company
</small>- Save index.html. Refresh the browser to see the changes.
- Change border='1' to border='0' in the <table> tag (just below the body tag).
- Save index.html. Refresh the browser to see the changes.