Hi All,

The title of this thread is the error i am recieving when running the script below.

Im hoping to get it to show all entried from the selected row.

<?php 
$dbh=mysql_connect ("------", "--------", "-----------") or die 
('I cannot connect to the database because: ' . mysql_error()); 
mysql_select_db ("silverlink"); 
$rs = mysql_query("SELECT max(post_id), post_text, post_create_time FROM forum_posts ") or die
(mysql_error());

while ( $rows = mysql_fetch_array( $rs) )
{
echo "<p>";
echo $rows[post_text];
echo "</p>";
}


?>

Hi there,
Enclose the phrase post_text in single quotes, like this:

echo $rows['post_text'];

That should sort out your error :)

Just the ticket, thank you very much for your help

No prob job :)

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.