Hello
After some help please
I have a website which links to a database.
I would like to be able to echo the contents of the database onto a new page.
The new page is generated with the following code;
echo '<tr><td align="left"><a href="word.php?w=' . $r['word'] . '">' . $r['word'] . '</a></td></tr>';
Is there a way that I can display rows of the database in the document word.php?
I thought if I did this it might work but it doesn't
$link = mysql_connect('host', 'db', 'pass');
if (!$link) {
die('Not connected : ' . mysql_error());
}
// access the required db
$db_selected = mysql_select_db('db', $link);
if (!$db_selected) {
die ('Can\'t use guide : ' . mysql_error());
}
echo '<td>' . $row['sentence1'] . '</td>';
Any ideas/pointers would be really appreciated.
Sorry if not clear - please say if not.