Update api/answer.php
This commit is contained in:
@@ -10,6 +10,13 @@ requireLogin();
|
|||||||
|
|
||||||
$user = $_SESSION['user'];
|
$user = $_SESSION['user'];
|
||||||
|
|
||||||
|
function normalize(string $s): string
|
||||||
|
{
|
||||||
|
$s = strtolower(trim($s));
|
||||||
|
$s = preg_replace('/\s+/', ' ', $s);
|
||||||
|
return $s;
|
||||||
|
}
|
||||||
|
|
||||||
$input = json_decode(file_get_contents('php://input'), true);
|
$input = json_decode(file_get_contents('php://input'), true);
|
||||||
|
|
||||||
$lang = $input['lang'];
|
$lang = $input['lang'];
|
||||||
|
|||||||
Reference in New Issue
Block a user