$query = mysql_query("select phone from nav where id='1'");
$go = mysql_result($query,id);
echo("$go");
I'm not sure why you have this as 1: select phone from nav where id='1'
You said you wanted ID = 5. I'd put it in there:
select phone from nav where id = 5
Check out the docs on [man]mysql_result[/man]. I don't think that's the function you want to use (it goes by rows, not columns from the looks of it).
You might do something like:
$result = mysql_query("select phone from nav where id='5'");
$row = mysql_fetch_array($result);
echo($row['phone']);
A few pointers:
mysql_query returns a result. You had the variable name as $query. It will work, but may confuse you later on when you look at your code. I renamed it to $result so you know you're working with a result set, not a query string.
I used [man]mysql_fetch_array[/man]. You can also use [man]mysql_fetch_object[/man]. Notice I didn't include any error checking. If ID #5 doesn't exist, your script will bomb out with some ugly error messages. The links should have some examples of error checking.
You don't need quotes around $go in this line: echo("$go");. No quotes. You're making PHP work a little harder. Just echo($go); will do fine (and its less typing!).