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.
25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

25 lines
1.1 KiB

  1. <TITLE>Location Selection</TITLE>
  2. <?php
  3. include_once 'gw-connect.php';
  4. $con = new mysqli(DATABASE_HOST, DATABASE_USER, DATABASE_PASS, DATABASE_NAME);
  5. //all POST variable data under here
  6. $playerid = mysqli_real_escape_string($con, $_POST['playerid']);
  7. if ($con->connect_errno > 0){
  8. die ('Unable to connect to database [' . $db->connect_errno . ']');
  9. }
  10. $sqlmaploc = "SELECT * FROM treasurelocation";
  11. if (!$resultmap = $con->query($sqlmaploc)){
  12. die ('There was an error running the query [' . $con->error . ']');
  13. }
  14. echo '<BODY><CENTER><FORM METHOD="POST" ACTION="gw-record.php">';
  15. echo '<INPUT TYPE="HIDDEN" NAME="playerid" VALUE="' . $playerid . '">';
  16. echo '<SELECT NAME="locationid" onchange="this.form.submit()">';
  17. echo '<OPTION SELECTED DISABLED>Select a map location</OPTION>';
  18. while ($rowmap = $resultmap->fetch_array()){
  19. $locname = $rowmap['location'];
  20. $loclink = $rowmap['wikilink'];
  21. $locid = $rowmap['treasureid'];
  22. echo '<OPTION VALUE="' . $locid . '">' . $locname . '</OPTION>';
  23. }
  24. echo '</SELECT><NOSCRIPT><INPUT TYPE="SUBMIT" VALUE="Choose Map Location"></NOSCRIPT></FORM></CENTER></BODY>';
  25. ?>