Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- $usern = $_POST['username'];
- $passw = $_POST['password'];
- include 'config.php';
- if(isset($_POST["username"]) && isset($_POST["password"])) {
- mysql_connect($host,$username,$password);
- @mysql_select_db($database) or die( "Unable To Connect To Database $database");;
- $cusername = mysql_real_escape_string($usern);
- $cpassword = mysql_real_escape_string($passw);
- $hashedpw = $cpassword;
- mysql_query("INSERT INTO characters(username, password) VALUES('$cusername', '$hashedpw') ") or die(mysql_error());
- mysql_close();
- echo "<script>alert('Account Has Been Created Sucessfully!')</script>";
- }
- else
- {
- echo $html."<center><br>Error!<br></center>".$footer;
- }
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement