ここの情報は古いです。ご理解頂いた上でお取り扱いください。

source: OpenPNE/trunk/webapp/lib/auth.inc @ 404

Last change on this file since 404 was 404, checked in by ogawa, 15 years ago

ログイン情報保存をQUERY_STRINGで書き直し

File size: 750 bytes
Line 
1<?php
2/**
3 * @copyright 2005-2006 OpenPNE Project
4 * @license   http://www.php.net/license/3_01.txt PHP License 3.01
5 */
6
7require_once 'OpenPNE/Auth.php';
8
9$auth = new OpenPNE_Auth();
10$auth->setExpire($GLOBALS['OpenPNE']['common']['session_lifetime']);
11$auth->setIdle($GLOBALS['OpenPNE']['common']['session_idletime']);
12
13if (   !$auth->auth()
14    || !($u = _db_c_member_id4pc_address_encrypted($auth->getUsername()))
15    || db_member_is_login_rejected($u)) {
16    $auth->logout();
17
18    if (LOGIN_URL_PC) {
19        client_redirect_absolute(get_login_url());
20    } else {
21        $_REQUEST['login_params'] = $_SERVER['QUERY_STRING'];
22        openpne_forward('pc', 'page', "o_login");
23        exit;
24    }
25}
26
27$auth->uid($u);
28$GLOBALS['AUTH'] = $auth;
29
30?>
Note: See TracBrowser for help on using the repository browser.