Jump to content

PARSE error Can't find


desjardins2010

Recommended Posts

line 11 the while loop

 

<?php
//include connect
$connect = mysql_connect("localhost","root","") or die ("Could Not Connect To Server");
mysql_select_db('npcs') or die ("Could Not Select Database");

$query = mysql_query("SELECT * FROM npc WHERE LEVEL=1") or die ("Could Not query Database");


echo "<table width='220' border='1' align='center'><tr><th>NPC NAME</th><th>JOB DESCRIPTION</th></tr><tr><th>LEVEL</th></tr><tr><th>EXPERIENCE</th></tr><tr><th>CASH</th></tr><tr><th>REPUTATION</th></tr>"


while ($row = mysql_fetch_array($query)) {


//set varibles from query
$npcname = $row['npcname'];
$level = $row['level'];
$jobdes = $row['jobdes'];
$exper = $row['exper'];
$cash = $row['cash'];
$rep = $row['rep'];
//end getting varibles

echo "<tr align='center'><td>{$row['npcname']}</td><td>{$row['jobdes']}</td><td>{$row['level']}</td><td>{$row['exper']}</td><td>{$row['cash']}</td><td>{$row['rep']}</td></tr>";

}

?>

Link to comment
https://forums.phpfreaks.com/topic/221652-parse-error-cant-find/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.