Exemple #1
0
        if (!empty($locale)) {
            //	set his prefered language
            setupCurrentLocale($locale);
        }
    }
}
if (!$_zp_loggedin) {
    //	Clear the ssl cookie
    zp_clearCookie("zenphoto_ssl");
    if (class_exists('ipBlocker')) {
        ipBlocker::load();
    }
}
// Handle a logout action.
if (isset($_REQUEST['logout'])) {
    $location = Zenphoto_Authority::handleLogout();
    zp_clearCookie("zenphoto_ssl");
    if (empty($location)) {
        $redirect = '?fromlogout';
        if (isset($_GET['p'])) {
            $redirect .= "&p=" . sanitize($_GET['p']);
        }
        if (isset($_GET['searchfields'])) {
            $redirect .= "&searchfields=" . sanitize($_GET['searchfields']);
        }
        if (isset($_GET['words'])) {
            $redirect .= "&words=" . sanitize($_GET['words']);
        }
        if (isset($_GET['date'])) {
            $redirect .= "&date=" . sanitize($_GET['date']);
        }
Exemple #2
0
        $_zp_current_admin_obj->lastlogon = $_zp_current_admin_obj->get('loggedin');
        $locale = $_zp_current_admin_obj->getLanguage();
        if (!empty($locale)) {
            //	set his prefered language
            setupCurrentLocale($locale);
        }
        $_zp_loggedin = zp_apply_filter('authorization_cookie', $_zp_loggedin);
    }
}
if (!$_zp_loggedin) {
    //	Clear the ssl cookie
    zp_setCookie("zenphoto_ssl", "", -368000);
}
// Handle a logout action.
if (isset($_REQUEST['logout'])) {
    $_zp_authority->handleLogout();
    zp_setCookie("zenphoto_ssl", "", -368000);
    $redirect = '';
    if (isset($_GET['p'])) {
        $redirect .= "&p=" . sanitize($_GET['p']);
    }
    if (isset($_GET['searchfields'])) {
        $redirect .= "&searchfields=" . sanitize($_GET['searchfields']);
    }
    if (isset($_GET['words'])) {
        $redirect .= "&words=" . sanitize($_GET['words']);
    }
    if (isset($_GET['date'])) {
        $redirect .= "&date=" . sanitize($_GET['date']);
    }
    if (isset($_GET['album'])) {