diff --git a/www/runtest.php b/www/runtest.php index 5f520b38aa..884f3b8cf6 100644 --- a/www/runtest.php +++ b/www/runtest.php @@ -146,7 +146,7 @@ } if (array_key_exists('resubmit', $_POST)) { $test = GetTestInfo(trim($_POST['resubmit'])); - if (array_key_exists('key', $test)) { + if (array_key_exists('key', $test)){ $test['key'] = null; } if ($test) { @@ -221,7 +221,7 @@ $is_private = 0; $is_private_api_call = !empty($user_api_key) && !empty($req_private) && - ((int)$req_private == 1 || $req_private == 'true'); + ((int)$req_private == 1 || $req_private == 'true'); $is_private_web_call = $isPaid && ($_POST['private'] == 'on'); if ($is_private_api_call || $is_private_web_call) { @@ -908,7 +908,6 @@ function buildSelfHost($hosts) $error = 'Please verify your email address to use WebPageTest.'; } - if (!strlen($error) && CheckIp($test) && CheckUrl($test['url']) && CheckRateLimit($test, $error, $errorTitle)) { $total_runs = Util::getRunCount($test['runs'], $test['fvonly'], $test['lighthouse'], $test['type']); $hasRunsAvailable = !is_null($request_context->getUser()) && $request_context->getUser()->hasEnoughRemainingRuns($total_runs); @@ -1835,24 +1834,9 @@ function ValidateParameters(&$test, $locations, &$error, $destination_url = null // make sure on/off options are explicitly 1 or 0 $values = array( - 'private', - 'web10', - 'ignoreSSL', - 'tcpdump', - 'standards', - 'lighthouse', - 'timeline', - 'swrender', - 'netlog', - 'spdy3', - 'noscript', - 'fullsizevideo', - 'blockads', - 'sensitive', - 'pngss', - 'bodies', - 'htmlbody', - 'pss_advanced', + 'private', 'web10', 'ignoreSSL', 'tcpdump', 'standards', 'lighthouse', + 'timeline', 'swrender', 'netlog', 'spdy3', 'noscript', 'fullsizevideo', + 'blockads', 'sensitive', 'pngss', 'bodies', 'htmlbody', 'pss_advanced', 'noheaders' ); foreach ($values as $value) { @@ -3578,7 +3562,7 @@ function CheckRateLimit($test, &$error, &$errorTitle) $errorTemplate = "

Don't worry! You can keep testing for free once you log in, which will give you access to other excellent features like:

"; $errorTitleTemplate = "You've reached the limit for"; - + if (!$passesMonthly) { $errorTitle = "{$errorTitleTemplate} this month"; $error = $errorTemplate;