Just a web script to help track when, where, and what you got from the free treasures scattered about Nightfall in the game Guild Wars.
Não pode escolher mais do que 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.
 
 
 

23 linhas
949 B

  1. <?php
  2. $cnameid = $_GET['toonid']; //need to sanitize this input somehow
  3. include_once 'gw-connect.php';
  4. $con = new mysqli(DATABASE_HOST, DATABASE_USER, DATABASE_PASS, DATABASE_NAME);
  5. if ($con->connect_errno > 0){
  6. die ('Unable to connect to database [' . $db->connect_errno . ']');
  7. }
  8. $sql = "SELECT * FROM `history` WHERE `charname` = '$cnameid' ORDER BY `historydate` ASC";
  9. if (!$result = $con->query($sql)){
  10. die ('There was an error running the query [' . $con->error . ']');
  11. }
  12. while ($row = $result->fetch_array()){
  13. echo 'On ' . $row['historydate'] . ', "' . $row['charname'] . '" got ' . $row['goldrec'] . 'GP and ';
  14. if (is_null($row['material'])) {
  15. echo 'a ' . $row['itemrarity'] . ' req' . $row['itemreq'] . ' ' . $row['itemattribute'] . ' ' . $row['itemtype'] . ' named something stupid <BR />';
  16. } else {
  17. echo 'a ' . $row['material'] . '!<BR />';
  18. } //add another else statement to cover RUNES here
  19. }
  20. ?>
  21. <TITLE>Treasure Dates</TITLE>