made search request more forgiving

This commit is contained in:
hnhx 2022-02-20 23:13:10 +01:00
parent 11d68fb57a
commit 4641f09672
1 changed files with 2 additions and 2 deletions

View File

@ -60,8 +60,8 @@
require_once "tools.php";
require_once "config.php";
$page = (int) htmlspecialchars($_REQUEST["p"]);
$type = (int) $_REQUEST["type"];
$page = isset($_REQUEST["p"]) ? (int) htmlspecialchars($_REQUEST["p"]) : 0;
$type = isset($_REQUEST["type"]) ? (int) $_REQUEST["type"] : 0;
$start_time = microtime(true);
$results = get_google_results($query, $page, $type);