Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include_once ("connection.php");
- if($_SERVER['REQUEST_METHOD'] == 'POST') {
- $reg_username = $_POST['reg_username'];
- $reg_password = $_POST['reg_password'];
- $reg_username = stripslashes($reg_username);
- $reg_password = stripslashes($reg_password);
- $reg_password = md5($reg_password);
- $reg_admin_query = "INSERT INTO admin (`username`,`password`)
- VALUES ('$reg_username','$reg_password')";
- if (!mysql_query($reg_admin_query, $connection)) {
- echo mysql_error();
- }
- mysql_close();
- echo "New admin registered";
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement