Sanitize word input to prevent errors
This commit is contained in:
parent
812d25c5d5
commit
9e81263f32
@ -32,6 +32,8 @@ try {
|
||||
if (!empty($_GET["words"])) {
|
||||
// convert words to coordinates
|
||||
$words = urldecode($_GET["words"]);
|
||||
$words = trim(strtolower($words));
|
||||
$words = preg_replace('/\s+/', ' ', $words);
|
||||
$coords = FixPhrase::decode($words);
|
||||
|
||||
$output = [
|
||||
|
Loading…
x
Reference in New Issue
Block a user