mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-12-25 01:51:00 +03:00
16 lines
408 B
PHP
16 lines
408 B
PHP
|
<?php
|
||
|
header("Content-Type: text/plain; charset=UTF-8");
|
||
|
|
||
|
// Verify login and password
|
||
|
$login = $_GET['login'];
|
||
|
$password = $_GET['password'];
|
||
|
if(empty($login) || empty($password)) {
|
||
|
exit('Empty login or password');
|
||
|
}
|
||
|
|
||
|
// Try authenticate
|
||
|
require_once('wp-load.php');
|
||
|
$user = wp_authenticate($login, $password);
|
||
|
echo($user instanceof WP_User ? 'OK:' . $user->user_login : 'Incorrect login or password');
|
||
|
?>
|