<?
$link = mysql_connect(’localhost’, ‘root’, ‘password’);
if (!$link) {
die(’Could not connect: ‘ . mysql_error());
}
$db_selected = mysql_select_db(’jsfbasic’, $link);
$result = mysql_query(’SELECT * FROM recipe’, $link);
if (!$result) {
die(’Invalid query: ‘ . mysql_error());
}
while ($row = mysql_fetch_array($result)) {
echo $row[0] . ‘<br />’;
}
mysql_close($link);
?>