Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- session_start();
- $PhotoURL = $_GET['photo_id']; // Grab the album
- $servername = "localhost";
- $username = "PKKIT"; // Set up the SQL server details.
- $password = "jeznicklogan";
- $dbname = "PKKIT";
- $AccountID = $_SESSION['AccountID'];
- // Create connection
- $conn = new mysqli($servername, $username, $password, $dbname);
- // Check connection
- if ($conn->connect_error) {
- die("Connection failed: " . $conn->connect_error);
- }
- $sql = mysqli_query($conn, "DELETE FROM photo WHERE file_url='$PhotoURL'"); // DELETE Album for Every user
- echo "<script>alert('The photo has been removed!');";
- echo "window.location='myphotos.php';</script>";
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement