-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathidentify_user.php
More file actions
30 lines (25 loc) · 894 Bytes
/
Copy pathidentify_user.php
File metadata and controls
30 lines (25 loc) · 894 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<?php
// Super Queue
// * Chinese translation: 董双丽
// * Graphics: 乔安
// * Code: Joan Alba Maldonado
$userName = "";
$userPassword = "";
$userGender = getGet("gender");
//Tries to identify the user by cookies:
$userKeyword = getCookie("user_keyword");
if (!USE_COOKIES || $userKeyword === "") { $userKeyword = getGet("user_keyword"); }
//If the identification was not successfull, tries to identify the user by keyword:
if ($userKeyword !== "")
{
//Tries to get an user id using this keyword:
$userId = getUserIdFromKeyword($userKeyword);
//If there is someone who uses this keyword:
if (is_numeric($userId) && $userId > 0)
{
//Gets the user name and password (these variables will be set in JavaScript):
$userName = trim(getUserName($userId));
$userPassword = trim(getUserPassword($userId));
$userGender = trim(getUserGender($userId));
}
}