Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php include("includes/header.php"); ?>
- <?php
- if($_COOKIE['enter'] != "")
- {
- header("Location: intropage.php");
- }
- if(isset($_POST["register"])){
- $CONNECT = mysqli_connect('localhost', 'litcoine_Trollbump', '4994797712alex', 'litcoine_project');
- if (!$CONNECT) {
- die('Ошибка соединения: ' . mysql_error());
- }
- echo("Успешно соединились");
- if(!empty($_POST['address']) && !empty($_POST['full_name']) && !empty($_POST['username']) && !empty($_POST['password'])) {
- $address=$_POST['address'];
- $full_name=$_POST['full_name'];
- $username=$_POST['username'];
- $password=md5(md5(md5(md5(md5($_POST['password'])))));
- //$CONNECT->query("SELECT * FROM users WHERE login='$username'");
- //$row = $result_set->fetch_assoc();
- $CONNECT->query("INSERT INTO users VALUES('$username', '$password', '$address', '$full_name', '0')");
- $message = "Account Successfully Created";
- //else
- //{
- //$message = "Failed to insert data information!";
- //}
- }
- else
- {
- $message = "All fields are required!";
- }
- }
- ?>
- <?php if (!empty($message)) {echo "<p class=\"error\">" . "MESSAGE: ". $message . "</p>";} ?>
- <div class="container mregister">
- <div id="login">
- <h1>REGISTER</h1>
- <form name="registerform" id="registerform" action="register.php" method="post">
- <p>
- <label for="user_login">MetaMask address<br />
- <input type="text" name="address" id="address" class="input" size="32" value="" /></label>
- </p>
- <p>
- <label for="user_pass">Full Name<br />
- <input type="text" name="full_name" id="full_name" class="input" value="" size="32" /></label>
- </p>
- <p>
- <label for="user_pass">Username<br />
- <input type="text" name="username" id="username" class="input" value="" size="20" /></label>
- </p>
- <p>
- <label for="user_pass">Password<br />
- <input type="password" name="password" id="password" class="input" value="" size="32" /></label>
- </p>
- <p class="submit">
- <input type="submit" name="register" id="register" class="button" value="Register" />
- </p>
- <p class="regtext">Already have an account? <a href="login.php" >Login Here</a>!</p>
- </form>
- </div>
- </div>
- <?php include("includes/footer.php"); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement