the else has to be balanced with an if.
go back to webmonkey and look at the line:
if ($myrow = mysql_fetch_array($result)) {
you need that to balance the else.
like the previous guy was saying, if you don't understand the code then try it without serious modifications. copy and paste new code into your scripts. change as little as possible to make it work. once you've got the basics, then try to change one thing at a time until you understand what the code does.