Advertisement
Guest User

Untitled

a guest
Feb 17th, 2017
267
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.87 KB | None | 0 0
  1. <?php
  2. /*Next Level*/
  3. $host = "localhost"; // MySQL Host
  4. $db = "rank2"; // Database name
  5. $username = "root"; // MySQL User
  6. $password = "pass"; // Password
  7. $connect=@mysql_connect($host,$username,$password);
  8. $select=@mysql_select_db($db,$connect);
  9. $sql=mysql_query("SELECT * from user Where uuid LIKE '%$unid%'");
  10. $resultnum = mysql_num_rows($sql);
  11. if($resultnum <= 0){
  12. }else{
  13. $sql = mysql_query("SELECT * FROM user WHERE uuid ='$unid'");
  14. while($row = mysql_fetch_object($sql)){
  15. $nextup = $row->nextup;
  16. $start_date = new DateTime('@0');
  17. $since_start = $start_date->diff(new DateTime("@$nextup"));
  18. $date1 = new DateTime('@0');
  19. $date2 = new DateTime("@$nextup");
  20. $diff = $date1->diff($date2, true);
  21. echo $diff->format('%m month %d days %H hours %I minutes %S seconds');}
  22. }
  23.  
  24. ++++++++++++++++++++++++++++++++++++
  25.  
  26. please check line 9,13
  27. what is wrong
  28. what is wrong
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement