Review

computer network clip artWe have learned an aweful lot of code, and a lot of rules for using that code. Let's see what you remember. Below, I've given you some code, and your job is to find the many mistakes I have made. Take your time, and go line by line. You are going to have to be the "great detective", because you can't ask for help on this one. You are on your own. That said, good luck, and happy hunting.

Practice Session

  1. Copy and paste the code below into a new Notepad file.
  2. Save as "detectivefile.html".
  3. Fix all mistakes.
  4. Open the file in your browser to see if you found all of the errors.
<html >
<title> The Great Detective File <title>
<head>
<link rel="stylesheet" type="text/css" href="detective.css"  />
</head

<body>
<p>That woman thinks she's goin to trip me up! 
I've been a great detective four years, and I can promise you this, 
I well find all of her mistakes.</li>
<h1>First Step</h2>
<ol>
<li>check for opening and closing tags</li>
<li>make sure all tags agree with each other</li>
<li>check the spelling, both in text and in tags</li>
<li>check the order of tags</li>

<h1>Next Step</h>
<p>Oh, this is getting confusing. I thought I knew what I was doing. 
It was so much easier with someone standing nearby to guide me! 
Now I have to see if she has done the table correctly.
Women! You just can't trust them to make things easy for a guy.
They always have to speak in riddles, leave things out.
That's it! I bet she has also left some things out on purpose. 
Well, we'll just see about that!<p/>

<h1>Make a Chart</h>
<p>Oh, this is getting confusing. I thought I new what I was doing. 
This was so much easier with someone standing neasby to guide me! 
Now I have to see if she has done the table correctly.</p>

<table>
<tr>
  <th>Fruit</th>
  <td>Apples</td>
  <td>Oranges</td>
  <tr>Bananas</td>
  <td>Grapes</td>
  <td>Pears</td>
  <td>Melons</td>
  <tr>Stawberries</td>
</tr>
<tr>
  <th>Treats </th>
  <td>Gummies</td>
  <td>Chocolate</tr>
  <td>Payday</td>
  <td>Milky Way</td>
  <td>Snickers</tr>
  <td>Gum</td>
  <td>Mints</td>
</tr>
<tr>
  <tr>Drinks</tr>
  <td>Tea</td>
  <td>Water</td>
  <td>Milk</td>
  <td>Coffee</td>
  <td>Juice</td>
  <td>Coke</td>
  <th>Pepsi</th>
</tr>

Key in the following code for your CSS in a separate file. Label it "detective.css". Don't forget it add it to your web page. Hope you had fun finding all the errors.

body {
	font: medium Verdana, Arial, sans-serif;
	}
table {
	border: 1px #ccc solid;
	}
th, td {
	padding: 5px 10px 5px 10px;
	border: 1px #ccc solid;
	font-size: 90%;
	}