Guest User

page2.php

a guest
Apr 28th, 2016
158
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.54 KB | None | 0 0
  1. <?php
  2. ob_start();
  3. require_once 'includes/db.php';
  4. require_once 'includes/init.php';
  5. if (!($user -> LoggedIn()))
  6. {
  7. header('location: login.php');
  8. die();
  9. }
  10. if (!($user -> notBanned($odb)))
  11. {
  12. header('location: login.php');
  13. die();
  14. }
  15. ?>
  16. <!DOCTYPE html>
  17. <!--[if lt IE 7 ]><html lang="en" class="ie6 ielt7 ielt8 ielt9"><![endif]--><!--[if IE 7 ]><html lang="en" class="ie7 ielt8 ielt9"><![endif]--><!--[if IE 8 ]><html lang="en" class="ie8 ielt9"><![endif]--><!--[if IE 9 ]><html lang="en" class="ie9"> <![endif]--><!--[if (gt IE 9)|!(IE)]><!-->
  18. <html lang="en"><!--<![endif]-->
  19. <head>
  20. <title>Purchase</title>
  21. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  22. <link href="css/bootstrap.min.css" rel="stylesheet">
  23. <link href="css/bootstrap-responsive.min.css" rel="stylesheet">
  24. <link href="css/site.css" rel="stylesheet">
  25. <!--[if lt IE 9]><script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script><![endif]-->
  26. </head>
  27. <body>
  28.  
  29. <?php
  30. $plansql = $odb -> prepare("SELECT `users`.*,`plans`.`name`, `plans`.`mbt` FROM `users`, `plans` WHERE `plans`.`ID` = `users`.`membership` AND `users`.`ID` = :id LIMIT 1");
  31. $plansql -> execute(array(":id" => $_SESSION['ID']));
  32. $userInfo = $plansql -> fetch(PDO::FETCH_ASSOC);
  33. ?>
  34.  
  35. <h1>Abonnements a vie !</h1>
  36. </div>
  37. <table class="table grid table-striped table-bordered table-condensed">
  38. <thead><tr>
  39. <th>Nom du pack</th>
  40. <th>Expiration</th>
  41. <th>Outils</th>
  42. <th>Prix</th>
  43. <th>Acheter (PayPal)</th>
  44. </tr>
  45. </thead>
  46. <tbody>
  47. <tr>
  48. <?php
  49. $newssql = $odb -> query("SELECT * FROM `plans` ORDER BY `price` ASC");
  50. while($row = $newssql ->fetch())
  51. {
  52. echo '<td>'.$row['name'].'</td>
  53. <td>Lifetime</td>
  54. <td>Disponible</td>
  55. <td>'.$row['price'].'.00€</td>
  56. <td>
  57. <a href="order.php?id='.$row['ID'].'"><button class="btn btn-info" type="submit">
  58. <i class="icon-shopping-cart"></i> Buy Now !
  59. </button></a>
  60. </td>
  61. </tr>';
  62.  
  63. }
  64. ?>
  65. </tbody>
  66. </table>
  67. </div>
  68. </div>
  69. </div>
  70. <script src="js/jquery.min.js"></script>
  71. <script src="js/bootstrap.min.js"></script>
  72. <script src="js/site.js"></script>
  73. </body>
  74. </html>
Advertisement
Add Comment
Please, Sign In to add comment