Example #1
0
<?php

require_once __DIR__ . '/../common/autoload_cms.php';
require_once 'include/header.php';
if (isset($_GET['id']) && isset($_GET['confirm'])) {
    $userCollection = new UserCollection();
    $userCollection->remove(array('id' => $_GET['id']));
    header('Location: user_list.php');
}
?>

<div class="container">
    <h1>Are you sure you want to delete this user?</h1>

    <a href="user_delete.php?id=<?php 
echo $_GET['id'];
?>
&confirm=1" class="btn btn-danger">Yes</a>
    <a href="user_list.php" class="btn btn-default">No</a>
</div>

<?php 
require_once 'include/footer.php';