本文整理匯總了PHP中parent::aFeatures方法的典型用法代碼示例。如果您正苦於以下問題:PHP parent::aFeatures方法的具體用法?PHP parent::aFeatures怎麽用?PHP parent::aFeatures使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類parent
的用法示例。
在下文中一共展示了parent::aFeatures方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: __construct
public function __construct()
{
parent::$aFeatures = array('passCredentials' => true, 'getCredentials' => true, 'isAuthenticated' => true, 'getUser' => true, 'getUserId' => true, 'passNewPassword' => true, 'changePassword' => true, 'passNewPassword' => true, 'createUser' => true);
$this->DB = new CoreMySQLHandler();
// Open the MySQL database
if (!$this->DB->open(cfg('auth_mysql', 'dbhost'), cfg('auth_mysql', 'dbport'), cfg('auth_mysql', 'dbname'), cfg('auth_mysql', 'dbuser'), cfg('auth_mysql', 'dbpass'))) {
throw new NagVisException(l('Unable to open auth database'));
} else {
// Create initial db scheme if needed
if (!$this->DB->tableExist('users')) {
$this->DB->createInitialDb();
} else {
// Maybe an update is needed
$this->DB->updateDb();
}
}
}
示例2: __construct
public function __construct()
{
parent::$aFeatures = array('passCredentials' => true, 'getCredentials' => true, 'isAuthenticated' => true, 'getUser' => true, 'getUserId' => true, 'passNewPassword' => true, 'changePassword' => true, 'resetPassword' => true, 'createUser' => true);
$this->DB = new CoreSQLiteHandler();
// Open sqlite database
if (!$this->DB->open(cfg('paths', 'cfg') . 'auth.db')) {
throw new NagVisException(l('Unable to open auth database ([DB])', array('DB' => cfg('paths', 'cfg') . 'auth.db')));
} else {
// Create initial db scheme if needed
if (!$this->DB->tableExist('users')) {
$this->DB->createInitialDb();
} else {
// Maybe an update is needed
$this->DB->updateDb();
}
}
}