The DS.M homepage and stuff. https://dontsell.me/site
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

72 lines
3.6 KiB

  1. <?php
  2. require_once __DIR__ . "/settings.php";
  3. require_once __DIR__ . "/database.php";
  4. $plan = $_GET['plan'];
  5. if (!isset(PLANS[$plan])) {
  6. header("Location: /#pricing");
  7. die("Invalid plan chosen.");
  8. }
  9. ?>
  10. <!DOCTYPE HTML>
  11. <title><?php echo SITE_TITLE; ?></title>
  12. <?php
  13. include __DIR__ . '/inc/meta.php';
  14. include __DIR__ . '/inc/piwik.php';
  15. ?>
  16. <!-- Wrapper -->
  17. <div id="wrapper">
  18. <?php include __DIR__ . "/inc/header.php"; ?>
  19. <!-- Section -->
  20. <section id="one" class="main alt">
  21. <header class="accent1">
  22. <h1>Purchase</h1>
  23. </header>
  24. <div class="inner alt">
  25. <div class="content">
  26. <p>Purchase a month of service. If you are a new user, enter a username, password, and email to register with. If you are an existing user, enter your login username and password, check the renewal box, and enter a valid email address.</p>
  27. <?php
  28. if ($_GET["err"] == "renewinvaliduser") {
  29. echo "<div><b>You have selected the renew option, but the username you gave does not exist.</b></div>";
  30. } else if ($_GET['err'] == "usernameinvalid") {
  31. echo "<div><b>That username is not available. Please choose another.</b></div>";
  32. } else if ($_GET['err'] == "renewpasswrong") {
  33. echo "<div><b>The password is incorrect.</b></div>";
  34. } else if ($_GET['err'] == "bademail") {
  35. echo "<div><b>The email address is not in a valid format. Try again.</b></div>";
  36. } else if ($_GET['err'] == "shortpassword") {
  37. echo "<div><b>Your password is too short. It needs to be at least 8 characters long.</b></div>";
  38. } else if ($_GET['err'] == "commonpassword") {
  39. echo "<div><b>Your chosen password is in a <a href=\"https://github.com/danielmiessler/SecLists/tree/master/Passwords\">public list</a> of 1,000,000 common passwords, and is therefore insecure. Choose a better one.</b></div>";
  40. }
  41. ?>
  42. <form action="purchase2.php" method="POST">
  43. <label for="username">Username:</label>
  44. <input type="text" name="username" id="username" placeholder="Username" required />
  45. <br />
  46. <label for="password">Password:</label>
  47. <input type="password" name="password" id="password" placeholder="Password" required />
  48. <br />
  49. <label for="email">Email:</label>
  50. <input type="email" name="email" id="email" placeholder="dsm@example.com" required />
  51. <br />
  52. <input type="checkbox" name="renewing" id="renewing" value="1" /> <label for="renewing">This is a renewal</label>
  53. <br />
  54. <input type="hidden" name="plan" value="<?php echo $plan; ?>" />
  55. <p>By pressing the Next button, you agree to <a href="terms.php" target="_BLANK">these terms</a>.
  56. <br />
  57. <?php if ($plan != "free" && $clearnet == false) { ?>
  58. Note: The next page needs to load third-party clearnet code from Stripe to process your payment. If you don't want that, email dsm@netsyms.com and mention your preferred methods.
  59. <br />
  60. <?php } ?>
  61. <button type="submit">Next</button>
  62. </form>
  63. </div>
  64. </div>
  65. </section>
  66. <?php include __DIR__ . "/inc/footer.php"; ?>
  67. </div>
  68. <?php include __DIR__ . "/inc/scripts.php"; ?>