Advertisement
Guest User

Untitled

a guest
Jul 6th, 2017
68
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. <?php
  2. $dns="GunzDB";
  3. $user="sa";
  4. $pass="password";
  5. $connect=odbc_connect($dns, $user, $pass) or die ("Couldn't connect to the database, we're sorry...");
  6. odbc_exec($connect,"use GunzDB");
  7.  
  8. //get latest clan fight
  9. $query = odbc_exec($connect, "SELECT * FROM Clan WHERE RegDate = (SELECT MAX(RegDate) FROM Clan)");
  10. odbc_fetch_row($query);
  11. $name = odbc_result($query, "Name");
  12.  
  13. //writing the results to the screen
  14. echo "Newest Clan: <b>".$name."</b>";
  15. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement