Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <!doctype html>
- <html>
- <?php
- require_once("index.php");
- ?>
- <head>
- <title> Login to UberU </title>
- </head>
- <body>
- <div name = "main" align = "center">
- <h1><u><font face = "arial" style = "color:black"> UberU LOGIN </font></u></h1>
- <form method = "post">
- Username:<input type = "text" name = "username" size = "width:300px"> <br> <br>
- Password:<input type = "password" name = "password" size = "width:300px" style = "margin-left:4px"> <br> <br>
- <input type = "submit" name = "loginButton" value = "Login" style = "margin-left:10px">
- </form>
- <?php
- $username = "null";
- $password = "null";
- if(isset($_POST["username"])) {
- $username = $_POST["username"];
- }
- if(isset($_POST["password"])) {
- $password = $_POST["password"];
- }
- if($username&&$password) {
- $connect = mysqli_connect("localhost:8080","root", "") or die ("ERROR: Connection failed...");
- mysqli_select_db("users") or die("ERROR: Couldn't find database...");
- }
- else {
- die("Please enter a username and a password...");
- }
- ?>
- <form action = "createAccount.php" method = "post">
- <br> <br> <br> Don't have an account yet? Click <input type = "submit" value = "here!">
- </form>
- </div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement