当前位置: 首页>>代码示例>>PHP>>正文


PHP ADODB_Session::password方法代码示例

本文整理汇总了PHP中ADODB_Session::password方法的典型用法代码示例。如果您正苦于以下问题:PHP ADODB_Session::password方法的具体用法?PHP ADODB_Session::password怎么用?PHP ADODB_Session::password使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ADODB_Session的用法示例。


在下文中一共展示了ADODB_Session::password方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: open

 function open($save_path, $session_name, $persist = null)
 {
     $conn =& ADODB_Session::_conn();
     if ($conn) {
         return true;
     }
     $database = ADODB_Session::database();
     $debug = ADODB_Session::debug();
     $driver = ADODB_Session::driver();
     $host = ADODB_Session::host();
     $password = ADODB_Session::password();
     $user = ADODB_Session::user();
     if (!is_null($persist)) {
         ADODB_Session::persist($persist);
     } else {
         $persist = ADODB_Session::persist();
     }
     # these can all be defaulted to in php.ini
     #		assert('$database');
     #		assert('$driver');
     #		assert('$host');
     $conn =& ADONewConnection($driver);
     if ($debug) {
         $conn->debug = true;
         //			ADOConnection::outp( " driver=$driver user=$user pwd=$password db=$database ");
     }
     if ($persist) {
         switch ($persist) {
             default:
             case 'P':
                 $ok = $conn->PConnect($host, $user, $password, $database);
                 break;
             case 'C':
                 $ok = $conn->Connect($host, $user, $password, $database);
                 break;
             case 'N':
                 $ok = $conn->NConnect($host, $user, $password, $database);
                 break;
         }
     } else {
         $ok = $conn->Connect($host, $user, $password, $database);
     }
     if ($ok) {
         $GLOBALS['ADODB_SESS_CONN'] =& $conn;
     } else {
         ADOConnection::outp('<p>Session: connection failed</p>', false);
     }
     return $ok;
 }
开发者ID:amjadtbssm,项目名称:website,代码行数:49,代码来源:adodb-session.php

示例2: define

$ADODB_SESS_LIFE = $lifetime;
if ($optimize) {
    define('ADODB_SESSION_OPTIMIZE', $optimize);
}
define('ADODB_SESSION_SYNCH_SECS', $sync_seconds);
if (class_exists('ADODB_Session')) {
    ADODB_Session::clob($clob);
    ADODB_Session::dataFieldName($data_field_name);
    ADODB_Session::database($database);
    ADODB_Session::debug($debug);
    ADODB_Session::driver($driver);
    ADODB_Session::filter($filters);
    ADODB_Session::host($host);
    ADODB_Session::lifetime($lifetime);
    ADODB_Session::optimize($optimize);
    ADODB_Session::password($password);
    ADODB_Session::syncSeconds($sync_seconds);
    ADODB_Session::table($table);
    ADODB_Session::user($user);
}
function NotifyFn($var, $sesskey)
{
    echo "NotifyFn({$var}, {$sesskey}) called<br />\n";
}
if ($expire_notify) {
    $ADODB_SESSION_EXPIRE_NOTIFY = array('debug', 'NotifyFn');
    if (class_exists('ADODB_Session')) {
        ADODB_Session::expireNotify(array('debug', 'NotifyFn'));
    }
}
session_start();
开发者ID:Artea,项目名称:freebeer,代码行数:31,代码来源:adodb-session-demo.php

示例3: open

 function open($save_path, $session_name, $persist = null)
 {
     $conn =& ADODB_Session::_conn();
     if ($conn) {
         return true;
     }
     $database = ADODB_Session::database();
     $debug = ADODB_Session::debug();
     $driver = ADODB_Session::driver();
     $host = ADODB_Session::host();
     $password = ADODB_Session::password();
     $user = ADODB_Session::user();
     if (!is_null($persist)) {
         $persist = (bool) $persist;
         ADODB_Session::persist($persist);
     } else {
         $persist = ADODB_Session::persist();
     }
     # these can all be defaulted to in php.ini
     #		assert('$database');
     #		assert('$driver');
     #		assert('$host');
     //print "driver is   ". $host. $user. $password. $driver;
     // cannot use =& below - do not know why...
     $conn = ADONewConnection($driver);
     if ($debug) {
         $conn->debug = true;
         //			ADOConnection::outp( " driver=$driver user=$user pwd=$password db=$database ");
     }
     if ($persist) {
         $ok = $conn->PConnect($host, $user, $password, $database);
     } else {
         $ok = $conn->Connect($host, $user, $password, $database);
     }
     if ($ok) {
         $GLOBALS['ADODB_SESS_CONN'] =& $conn;
     } else {
         ADOConnection::outp('<p>Session: connection failed</p>', false);
     }
     return $ok;
 }
开发者ID:nateirwin,项目名称:custom-historic,代码行数:41,代码来源:adodb-session.php

示例4: config

 function config($driver, $host, $user, $password, $database = false, $options = false)
 {
     ADODB_Session::driver($driver);
     ADODB_Session::host($host);
     ADODB_Session::user($user);
     ADODB_Session::password($password);
     ADODB_Session::database($database);
     if ($driver == 'oci8' || $driver == 'oci8po') {
         $options['lob'] = 'CLOB';
     }
     if (isset($options['table'])) {
         ADODB_Session::table($options['table']);
     }
     if (isset($options['lob'])) {
         ADODB_Session::clob($options['lob']);
     }
     if (isset($options['debug'])) {
         ADODB_Session::debug($options['debug']);
     }
 }
开发者ID:BackupTheBerlios,项目名称:nxwcms-svn,代码行数:20,代码来源:adodb-session2.php

示例5: ini_set

if ($gBitSystem->isFeatureActive('site_session_lifetime')) {
    ini_set('session.gc_maxlifetime', $gBitSystem->isFeatureActive('site_session_lifetime'));
}
// is session data stored in DB or in filesystem?
if ($gBitSystem->isFeatureActive('site_store_session_db') && !empty($gBitDbType)) {
    if (file_exists(EXTERNAL_LIBS_PATH . 'adodb/session/adodb-session.php')) {
        include_once EXTERNAL_LIBS_PATH . 'adodb/session/adodb-session.php';
    } elseif (file_exists(UTIL_PKG_PATH . 'adodb/session/adodb-session.php')) {
        include_once UTIL_PKG_PATH . 'adodb/session/adodb-session.php';
    }
    if (class_exists('ADODB_Session')) {
        ADODB_Session::dataFieldName('session_data');
        ADODB_Session::driver($gBitDbType);
        ADODB_Session::host($gBitDbHost);
        ADODB_Session::user($gBitDbUser);
        ADODB_Session::password($gBitDbPassword);
        ADODB_Session::database($gBitDbName);
        ADODB_Session::table(BIT_DB_PREFIX . 'sessions');
        ini_set('session.save_handler', 'user');
    }
}
session_name(BIT_SESSION_NAME);
if ($gBitSystem->isFeatureActive('users_remember_me')) {
    session_set_cookie_params($gBitSystem->getConfig('site_session_lifetime'), $gBitSystem->getConfig('cookie_path', BIT_ROOT_URL), $gBitSystem->getConfig('cookie_domain', ''));
} else {
    session_set_cookie_params($gBitSystem->getConfig('site_session_lifetime'), BIT_ROOT_URL, '');
}
// just use a simple COOKIE (unique random string) that is linked to the users_cnxn table.
// This way, nuking rows in the users_cnxn table can log people out and is much more reliable than SESSIONS
global $gShellScript;
if (empty($gShellScript)) {
开发者ID:bitweaver,项目名称:users,代码行数:31,代码来源:bit_setup_inc.php


注:本文中的ADODB_Session::password方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。