Ahh.. this has been working a buch of times for me.. but now its being retarded!
Im trying to pull stuff from my Mysql database.. I can insert it and stuff..
$sql = "SELECT * FROM news";
$result = mysql_query($sql);
if(!($result = mysql_query($sql))) die(mysql_error());
if(mysql_num_rows($result) == 1) {
$row = mysql_fetch_array($result);
echo ".::" .$row[topic]. "::.<br> <i>Posted by: " .$row[author]. " on " .$row[date]. "</i><br>";
echo "$row[message]";
}
When I have 2 things in my Database it displays nothing.. but when I have one i get
Notice: Use of undefined constant topic - assumed 'topic' in C:\Program Files\Abyss Web Server\htdocs\jimmy\index.php on line 306
Notice: Use of undefined constant date - assumed 'date' in C:\Program Files\Abyss Web Server\htdocs\jimmy\index.php on line 306
.::This is a test::.
Posted by: Brandon on 0000-00-00
Hi.. this is brandon testing addnews.