示例#1
0
}
if (!$login->isAdmin() && !$login->isStaff()) {
    header('location: voir_adherent.php');
    die;
}
use Galette\Core;
$mailhist = new Core\MailingHistory();
if (isset($_GET['reset']) && $_GET['reset'] == 1) {
    $mailhist->clean();
    //reinitialize object after flush
    $mailhist = new Core\MailingHistory();
}
//delete mailings
if (isset($_GET['sup']) || isset($_POST['delete'])) {
    if (isset($_GET['sup'])) {
        $mailhist->removeEntries($_GET['sup']);
    } else {
        if (isset($_POST['member_sel'])) {
            $mailhist->removeEntries($_POST['member_sel']);
        }
    }
}
if (isset($_GET['page']) && is_numeric($_GET['page'])) {
    $mailhist->current_page = (int) $_GET['page'];
}
if (isset($_GET['nbshow']) && is_numeric($_GET['nbshow'])) {
    $mailhist->show = $_GET['nbshow'];
}
if (isset($_GET['tri'])) {
    $mailhist->orderby = $_GET['tri'];
}