Advertisement
Guest User

Untitled

a guest
Oct 5th, 2014
215
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.34 KB | None | 0 0
  1. <style>
  2.  
  3. * {
  4. text-align:center;
  5. font-family:Segoe UI;
  6.  
  7. </style>
  8.  
  9. <html lang="en">
  10. <head>
  11. <meta charset="utf-8">
  12. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  13. <meta name="viewport" content="width=device-width, initial-scale=1">
  14. <meta name="description" content="">
  15. <meta name="author" content="">
  16. <link rel="icon" href="../../favicon.ico">
  17.  
  18. <title>TTUL Registration Page</title>
  19.  
  20. <!-- Bootstrap core CSS -->
  21. <link href="css/bootstrap.min.css" rel="stylesheet">
  22.  
  23. <!-- Custom styles for this template -->
  24. <link href="signin.css" rel="stylesheet">
  25.  
  26. <!-- Just for debugging purposes. Don't actually copy these 2 lines! -->
  27. <!--[if lt IE 9]><script src="../../assets/js/ie8-responsive-file-warning.js"></script><![endif]-->
  28. <script src="../../assets/js/ie-emulation-modes-warning.js"></script>
  29.  
  30. <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
  31. <!--[if lt IE 9]>
  32. <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script>
  33. <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script>
  34. <![endif]-->
  35. </head>
  36.  
  37.  
  38. <form action="register.php" method="POST">
  39. <body>
  40. <h2><strong>
  41.  
  42. <div class="container">
  43.  
  44. <form class="form-signin" role="form">
  45. <h2 class="form-signin-heading">Please Fill Out Information Fields To Register.</h2>
  46. <br />
  47. <br />
  48. <div class="well">
  49. <input type="firstname" class="form-control" placeholder="First Name" name="fname" required autofocus>
  50. <br />
  51. <br />
  52. <input type="lastname" class="form-control" placeholder="First Name" name="lname" required autofocus>
  53. <br />
  54. <br />
  55. <input type="email" class="form-control" placeholder="Email address" name="email" required autofocus>
  56. <br />
  57. <br />
  58. <input type="text" class="form-control" placeholder="IGN" name="username" required>
  59. <br />
  60. <br />
  61. <input type="password" class="form-control" placeholder="Password" name="password" required>
  62. <br />
  63. <br />
  64. <button class="btn btn-lg btn-primary btn-block" type="submit">Register</button>
  65. </div>
  66. </form>
  67. </div> <!-- /container -->
  68. <!-- IE10 viewport hack for Surface/desktop Windows 8 bug -->
  69. <script src="../../assets/js/ie10-viewport-bug-workaround.js"></script>
  70. </h1>
  71. </strong>
  72. </form>
  73. </body>
  74. </html>
  75.  
  76.  
  77. <?php
  78. $username = "username";
  79. $password = "password";
  80. $hostname = "localhost";
  81.  
  82. $databasehandle = mysql_connect($hostname, $username, $password) or die("Couldn't Connect to the database!");
  83.  
  84. $selected = mysql_select_db("toontow7_login", $databasehandle);
  85.  
  86. if(isset($_POST['username'] && isset($_POST['password']) && isset($_POST['fname']) && isset($_POST['lname']) && isset($_POST['email']))) {
  87. $user = $_POST['username'];
  88. $pass = $_POST['password'];
  89. mysql_query("INSERT INTO users (Username, Password) VALUES ($user, $pass)");
  90. echo("
  91. <html>
  92. <body>
  93. <h1>
  94. User created Successfully.
  95. </h1>
  96. <h2>
  97. <a href='login.php' style='text-decoration:none;'>
  98. Click Here to go to Login Page.
  99. </h2>
  100. </a>
  101. </body>
  102. </html> ")
  103. }
  104.  
  105. else {
  106. echo '
  107. <script type="text/javascript">
  108. alert("Please Fill Out the Registeration Form Correctly.");</script>';
  109. die(mysql_error());
  110. }
  111.  
  112.  
  113. mysql_close();
  114. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement