Web Hosting Talk







View Full Version : PHP page problem


xaero
11-19-2002, 11:28 PM
Ok so i decided to designmy own php sign up page for lan parties. I got the database setup and it stores everything it needs to. Then i created a page to display all of the people who sign up into a table. Problem is this page is giving me all types of problems and would like to get a second opinion from a more experienced programmer.

to see the error check out http://www.paulsation.com/gaming/register/view.php

to see the ascii code for the view.php check out
http://www.paulsation.com/gaming/register/view.php.txt

if you figure out the problem please email me at justin@paulsation.com

myg-
11-20-2002, 12:06 AM
You have a few syntax errors.. try this.


<?php
// Connect to the database
$db = mysql_connect("localhost","root",":P");
mysql_select_db (registered);
// Ask the database for the information from the links table
echo "<table border = '0' width = '100%' align='center'>";

$query = "SELECT * FROM 'people'";
$result = mysql_query($query);
while ($rows = mysql_fetch_row($result))
// Here we make the script keep making new rows until all the links in our database are shown, this is called a loop
{
echo "<tr><td><A HREF='$rows[2]'>$rows[1]</A></td></tr>";
}
echo "</table>";
?>