use Column name in select statement as the variable name
|
<?php
mysql_connect("mysql153.secureserver.net","navioo","password"); mysql_select_db("navioo");
$query = "SELECT id, firstname FROM Employee"; $result = mysql_query($query);
while (list($id, $name) = mysql_fetch_row($result)) { echo "$name ($id) <br />"; }
?>
|
|
|
|
|
HTML code for linking to this page:
|