Help SQL -> PHP > into HTML

So I have this code, [php]$con=mysql_connect(“localhost”,“root”,"");
$db_found = mysql_select_db(“test”);

$result = mysql_query(“SELECT * FROM bans”);
echo "

"; while($row = mysql_fetch_array($result)) { echo ""; echo ""; echo ""; echo ""; } echo "
Firstname Lastname
" . $row['_SteamName'] . "" . $row['_Reason'] . "
";

?>

Half Life 2: Roleplay Top Players

Sort by
Server IDMember IDSubmission DateLast Updated DateRatingViewsServer NameIP AddressCurrent PlayersMax PlayersMapStatusGame

Sort order
Ascending (A-Z)Descending (Z-A)

 
";?>
  Player Name Gender Faction Cash Flags Steam Name  
  <?= " " . $row['_Reason'] . "  
[/php]

I need the [php] echo “

” . $row[’_Reason’] . “”;[/php] to appear into the HTML table! Thanks :smiley:

You should change to a newer library for interacting with databases
http://www.phphelp.com/forum/the-occasional-tutorial/using-php-with-databases-(pdo-tutorial)/

And you should add whatever errors you are getting. Not getting any? Add this to the beginning of you script:
[php] ini_set(‘error_reporting’, E_ALL);
ini_set(‘display_errors’, ‘1’);[/php]

Sponsor our Newsletter | Privacy Policy | Terms of Service