mirror of
https://github.com/GravitLauncher/Launcher
synced 2025-04-01 22:14:01 +03:00
Fix ipb.php! (fixed locale).
This commit is contained in:
parent
f79799bee1
commit
6a9ce59a94
1 changed files with 5 additions and 5 deletions
|
@ -5,13 +5,13 @@ header("Content-Type: text/plain; charset=UTF-8");
|
|||
$login = $_GET['login'];
|
||||
$password = $_GET['password'];
|
||||
if(empty($login) || empty($password)) {
|
||||
exit('Empty login or password');
|
||||
exit('Введены неверные данные');
|
||||
}
|
||||
|
||||
// Load IPB core
|
||||
define('IPB_THIS_SCRIPT', 'public');
|
||||
require_once('initdata.php');
|
||||
require_once(IPS_ROOT_PATH . 'sources/base/ipsRegistry.php');
|
||||
require('initdata.php'); // not once!!!
|
||||
require(IPS_ROOT_PATH . 'sources/base/ipsRegistry.php');
|
||||
$reg = ipsRegistry::instance();
|
||||
$reg->init();
|
||||
|
||||
|
@ -19,10 +19,10 @@ $reg->init();
|
|||
$member = IPSMember::load(IPSText::parseCleanValue($login), 'all', 'username');
|
||||
$member_id = $member['member_id'];
|
||||
if (!$member_id) {
|
||||
exit('Incorrect login');
|
||||
exit('Введены неверные данные');
|
||||
}
|
||||
|
||||
// Try authenticate
|
||||
$success = IPSMember::authenticateMember($member_id, md5(IPSText::parseCleanValue($password)));
|
||||
echo($success ? 'OK:' . $member['name'] : 'Incorrect login or password');
|
||||
echo($success ? 'OK:' . $member['name'] : 'Ошибка при авторизации');
|
||||
?>
|
||||
|
|
Loading…
Reference in a new issue