本文整理汇总了PHP中Website::passwordsEncryption方法的典型用法代码示例。如果您正苦于以下问题:PHP Website::passwordsEncryption方法的具体用法?PHP Website::passwordsEncryption怎么用?PHP Website::passwordsEncryption使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Website
的用法示例。
在下文中一共展示了Website::passwordsEncryption方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: setPasswordsEncryption
public static function setPasswordsEncryption($encryption)
{
if (isset(self::$passwordsEncryptions[strtolower($encryption)])) {
self::$passwordsEncryption = strtolower($encryption);
} else {
new Error_Critic('#C-12', 'Invalid passwords encryption ( ' . htmlspecialchars($encryption) . '). Must be one of these: ' . implode(', ', self::$passwordsEncryptions));
}
}
示例2: updatePasswordEncryption
public static function updatePasswordEncryption()
{
$encryptionTypeLowerd = strtolower(self::getServerConfig()->getValue('passwordType'));
if (empty($encryptionTypeLowerd)) {
// TFS 1.1+
$encryptionTypeLowerd = $config['site']['encryptionType'];
if (empty($encryptionTypeLowerd)) {
$encryptionTypeLowerd = 'sha1';
}
}
if (isset(self::$passwordsEncryptions[$encryptionTypeLowerd])) {
self::$passwordsEncryption = $encryptionTypeLowerd;
} else {
new Error_Critic('#C-12', 'Invalid passwords encryption ( ' . htmlspecialchars($encryption) . '). Must be one of these: ' . implode(', ', self::$passwordsEncryptions));
}
}