Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <form action = "<?php $_PHP_SELF ?>" method = "POST">
- Profile = <input type = "text" name = "profile" />
- <input type = "submit" />
- </form>
- <?php
- $servername = "localhost";
- $username = "root";
- $password = "root";
- $dbname = "registration";
- $conn = new mysqli($servername, $username, $password, $dbname);
- if ($conn->connect_error) {
- die("Connection failed: " . $conn->connect_error);
- }
- $query = "DELETE FROM users WHERE id= profile";
- if ($conn->query($sql) === TRUE) {
- echo "Profile deleted successfully";
- } else {
- echo "Error deleting profile: " . $conn->error;
- }
- ?>
Add Comment
Please, Sign In to add comment