Problem creating Reports / Updatable .php files

i know that the problem is something very minor, but im relatively new to PHP/mySQL. im pretty proficient with HTML and much older coding languages, im talking C Basic and C+, and some Cobalt. anyways here is the code for my update.php, im getting an error on line 7, here is the error verbatim:

here is the code im using (this is just trying to get it to work, i am going to expand but no point if i can’t get my basic connections to work, building a ADD/LIST ALL with buttons on each entry for EDIT/UPDATE, but as i said cant even get basic stuff to work, i know it something minor. in the book i read it said to use mysql_numrows() but in dreamweaver it only recognizes mysql_num_rows() not sure which is wrong, help please both fail on live test!):

<?
include(“dbinfo.inc.php”);
mysql_connect($host,$username,$password);
mysql_select_db($database) or die( “Unable to select database”);
$query=“SELECT * FROM users WHERE id=’$id’”;
$result=mysql_query($query);
$num=mysql_num_rows($result);
mysql_close();
$i=0;
while ($i < $num) {
$first=mysql_result($result,$i,“first”);
$last=mysql_result($result,$i,“last”);
$phone=mysql_result($result,$i,“phone”);
$email=mysql_result($result,$i,“email”);
?>
<form action=“updated.php”>
<input type=“hidden” name=“ud_id” value="<? echo “$id”; ?>">
First Name: <input type=“text” name=“ud_first” value="<? echo “$first”?>"><br>
Last Name: <input type=“text” name=“ud_last” value="<? echo “$last”?>"><br>
Phone Number: <input type=“text” name=“ud_phone” value="<? echo “$phone”?>"><br>
E-mail Address: <input type=“text” name=“ud_email” value="<? echo “$email”?>"><br>
<input type=“Submit” value=“Update”>
</form>
<?
++$i;
}
?>

any and all help much appreciated, if someone doesnt mind PMs or prefers posting live, i will have a few more questions as i finish this project. thanks in advance from an old code monkey trying to catch up.:beer:

P.S. i doubt you need it, but im new so i will add my ‘updated.php’ script below as well since its included above, though my error hits on line 7 (the mysql_nom_row($result) line):

<?
include(“dbinfo.inc.php”);
mysql_connect($host,$username,$password);
$query=“UPDATE users SET first=’$ud_first’, last=’$ud_last’, phone=’$ud_phone’, email=’$ud_email’ WHERE id=’$ud_id’”;
mysql_select_db($database) or die( “Unable to select database”);
mysql_query($query);
echo “Record Updated”;
mysql_close();
?>