Sorry Kids, I am not a programmer and have taken over for somebody else here. I have moved my clients database and web site over to web hosting company. I have successfully uploaded the database on a Red Hat machine. I can log into the database from the MYSQL ADMIN tool from the control panel. I have setup the password correctly but I am getting this error message.
I have supplied the Code from the page:
<?php
$banner = mysql_query("SELECT * FROM banners WHERE visible='1'", $link);
$max = mysql_num_rows($banner);
if ($max !== 1){
$rand = mt_rand(1,$max);}else{
$rand = 1;}
$img = mysql_result($banner, $rand-1, 'id');
$type = mysql_result($banner, $rand-1, 'type');
$link = mysql_result($banner, $rand-1, 'link_text');
$banner_views = mysql_result($banner, $rand-1, 'views') + 1;
$update = mysql_query("UPDATE banners SET views='$banner_views' WHERE id='$img'");
echo "<a href=\"$link\">\n";
echo "<img src=\"banners/$img.$type\" width=120 height=240 border=0>\n";
echo "</a>\n";
?>
I am getting error messages on lines 3, 7, 8, 9, 10. For those of you laughing out there, I am not a programer so any assistance would be accepted. I can edit in Dreamweaver MX. I just went into the database to verify it is there.
What should I be looking for and what questions should I be asking?
Thank you,
Christopher