本文整理汇总了PHP中Authenticator::set_default_authenticator方法的典型用法代码示例。如果您正苦于以下问题:PHP Authenticator::set_default_authenticator方法的具体用法?PHP Authenticator::set_default_authenticator怎么用?PHP Authenticator::set_default_authenticator使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Authenticator
的用法示例。
在下文中一共展示了Authenticator::set_default_authenticator方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: tearDown
function tearDown()
{
// Restore selected authenticator
// MemberAuthenticator might not actually be present
if (!in_array('MemberAuthenticator', $this->priorAuthenticators)) {
Authenticator::unregister('MemberAuthenticator');
}
Authenticator::set_default_authenticator($this->priorDefaultAuthenticator);
parent::tearDown();
}
示例2: tearDown
function tearDown()
{
// Restore selected authenticator
// MemberAuthenticator might not actually be present
if (!in_array('MemberAuthenticator', $this->priorAuthenticators)) {
Authenticator::unregister('MemberAuthenticator');
}
Authenticator::set_default_authenticator($this->priorDefaultAuthenticator);
// Restore unique identifier field
Member::set_unique_identifier_field($this->priorUniqueIdentifierField);
parent::tearDown();
}
示例3: tearDown
public function tearDown()
{
// Restore selected authenticator
// MemberAuthenticator might not actually be present
if (!in_array('MemberAuthenticator', $this->priorAuthenticators)) {
Authenticator::unregister('MemberAuthenticator');
}
foreach ($this->priorAuthenticators as $authenticator) {
Authenticator::register($authenticator);
}
Authenticator::set_default_authenticator($this->priorDefaultAuthenticator);
// Restore unique identifier field
Member::config()->unique_identifier_field = $this->priorUniqueIdentifierField;
Security::config()->remember_username = $this->priorRememberUsername;
parent::tearDown();
}
示例4: tearDown
function tearDown()
{
/* Remove the test files that we've created */
$fileIDs = $this->allFixtureIDs('File');
foreach ($fileIDs as $fileID) {
$file = DataObject::get_by_id('File', $fileID);
if (file_exists(BASE_PATH . "/{$file->Filename}")) {
unlink(BASE_PATH . "/{$file->Filename}");
}
}
/* Remove the test folders that we've crated */
$fileIDs = array_reverse($this->allFixtureIDs('Folder'));
foreach ($fileIDs as $fileID) {
$file = DataObject::get_by_id('Folder', $fileID);
if (file_exists(BASE_PATH . "/{$file->Filename}")) {
rmdir(BASE_PATH . "/{$file->Filename}");
}
}
if (!in_array('MemberAuthenticator', $this->priorAuthenticators)) {
Authenticator::unregister('MemberAuthenticator');
}
Authenticator::set_default_authenticator($this->priorDefaultAuthenticator);
parent::tearDown();
}
示例5: set_include_path
* Authenticator::register_authenticator('OpenIDAuthenticator');
* </code>
*
* @package sapphire
* @subpackage core
*/
/**
* Add pear parser to include path
*/
$path = Director::baseFolder() . '/sapphire/parsers/';
set_include_path(get_include_path() . PATH_SEPARATOR . $path);
/**
* Register the {@link OpenIDAuthenticator OpenID authenticator}
*/
Authenticator::register_authenticator('MemberAuthenticator');
Authenticator::set_default_authenticator('MemberAuthenticator');
/**
* Define a default language different than english
*/
//i18n::set_locale('ca_AD');
/**
* The root directory of TinyMCE
*/
define('MCE_ROOT', 'jsparty/tiny_mce2/');
/**
* Should passwords be encrypted (TRUE) or stored in clear text (FALSE)?
*/
Security::encrypt_passwords(true);
/**
* Which algorithm should be used to encrypt? Should a salt be used to
* increase the security?