Guest User

Untitled

a guest
May 1st, 2012
40
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.93 KB | None | 0 0
  1. <?php
  2. $con = mysql_connect("fdb2.125mb.com","432788_weex","nicho1995w");
  3. if (!$con)
  4. {
  5. die('Could not connect: ' . mysql_error());
  6. }
  7.  
  8. $db_con = mysql_select_db("432788_weex", $con);
  9. if (!$db_con)
  10. {
  11. die('Could not connect to "432788_weex": ' . mysql_error());
  12. }
  13.  
  14. $result = mysql_query("SELECT * FROM users");
  15.  
  16. echo "<table border='1'>
  17. <tr>
  18. <th>PSN Navn</th>
  19. <th>E-Mail</th>
  20. <th>Sist p&aring;logget</th>
  21. </tr>";
  22.  
  23. while($row = mysql_fetch_array($result))
  24. {
  25. echo "<tr>";
  26. echo "<td>" . $row['user_name'] . "</td>";
  27. }
  28. if['user_level'] != 2 )
  29. {
  30. echo "<td><font color="red">" . $row['user_email'] . "</font></td>";
  31. }
  32. if['user_level'] != 1 )
  33. {
  34. echo "<td><font color="green">" . $row['user_email'] . "</font></td>";
  35. }
  36. else
  37. {
  38. echo "<td>" . $row['user_email'] . "</td>";
  39. echo "<td>" . $row['last_online'] . "</td>";
  40. echo "</tr>";
  41. }
  42. echo "</table>";
  43.  
  44. mysql_close($con);
  45. ?>
Advertisement
Add Comment
Please, Sign In to add comment