Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions src/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -892,11 +892,6 @@ function strip_empty_lines($s, $max_empty_lines) {
}
}

// if magic quotes is enabled then stripslashes will be needed
if (get_magic_quotes_gpc() == 1) {
$query = stripslashes($query);
}

// If no query, so show last documents
if (!$query) {
if ($cfg['newest_on_empty_query']) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
// no term passed - just exit early with no response
if (empty($_GET['term'])) exit ;
$q = strtolower($_GET["term"]);
// remove slashes if they were magically added
if (get_magic_quotes_gpc()) $q = stripslashes($q);

$items = array(
"Great Bittern"=>"Botaurus stellaris",
Expand Down Expand Up @@ -587,4 +585,4 @@
// json_encode is available in PHP 5.2 and above, or you can install a PECL module in earlier versions
echo json_encode($result);

?>
?>