Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!DOCTYPE html>
- <head>
- <title>Registration/Login</title>
- </head>
- <body>
- <center>
- <div>
- <form method="post">
- Registration<br><br>
- Username: <input type="text" id="username" name="username" value="<?php
- if (isset($_POST["username"])) {
- echo $_POST["username"];
- }
- ?>" required><br><br>
- Password: <input type="password" id="password" name="password" value="<?php
- if (isset($_POST["password"])) {
- echo $_POST["password"];
- }
- ?>" required><br><br>
- Repeat password: <input type="password" id="reppassword" name="reppassword" required/><br><br>
- E-mail: <input type="text" id="usermail" name="usermail"value="<?php
- if(isset($_POST["usermail"])){
- echo $_POST['usermail'];
- }
- ?>" required/>
- <br><br>
- <?php
- if(isset($_POST["password"]) and isset($_POST["reppassword"])) {
- if (trim($_POST["password"]) == "" or trim($_POST["reppassword"]) == "") {
- echo("All fields are required");
- }
- else if (($_POST["password"]) != ($_POST["reppassword"])) {
- echo("Passwords do not match");
- }
- }
- ?>
- <?php
- // email check
- ?>
- <br><br>
- <input type="submit" name="register" value="Submit"/><br><br>
- </form>
- <form methos="post">
- Login<br><br>
- Username: <input type="text" id="logusername" name="logusername"/><br><br>
- Password: <input type="password" id="logpassword" name="logpassword"/><br><br>
- <input type="submit" name="login" value="Submit"/><br><br>
- </form>
- </div>
- <div>
- <a href="Home.php">
- <input type="button" name="back" value="Back"/>
- </a>
- </div>
- </center>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement