connect_errno > 0){ die ('Unable to connect to database [' . $db->connect_errno . ']'); } echo 'At '; echo $location //code for selecting location from DB via locationid echo ' a/an '; //code for weapon attribute requirment $sqlweapreq = "SELECT * FROM `listreq` ORDER BY `req` ASC"; if (!$result = $con->query($sqlweapreq)){ die ('There was an error running the query [' . $con->error . ']'); } echo ''; //code for white blue purple etc $sqlweaprare = "SELECT * FROM `listrarity` ORDER BY `rareid` ASC"; if (!$result = $con->query($sqlweaprare)){ die ('There was an error running the query [' . $con->error . ']'); } echo ''; //code for what attribute the weapon is (command, axe mastery, energy storage, etc $sqlweapattr = "SELECT * FROM `listattribute` ORDER BY `weapattrid` ASC"; if (!$result = $con->query($sqlweapattr)){ die ('There was an error running the query [' . $con->error . ']'); } echo ''; echo ' |weapon/mat/rune code here|'; ?>