Commit 1d686544 authored by Brett Bieber's avatar Brett Bieber
Browse files

Do not show local search results for u=http://www.unl.edu/

parent 883c5bbf
......@@ -28,6 +28,7 @@ if ($template == 'Mobile') {
$page->addScript('searchFunc.js');
if (isset($_GET['u']) //u is referring site
&& $_GET['u'] !== 'http://www.unl.edu/'
&& preg_match('/^https?/', $_GET['u'])
&& filter_var($_GET['u'], FILTER_VALIDATE_URL, FILTER_FLAG_SCHEME_REQUIRED)
&& $scanned = @file_get_contents($_GET['u'])) {
......@@ -83,7 +84,7 @@ if (isset($_GET['u']) //u is referring site
$page->maincontentarea = '
<div id="searchform">
<form action="http://www1.unl.edu/search/" method="get">
<form action="./" method="get">
<label for="q">Search</label>
<input type="text" name="q" id="q" />';
if (!empty($local_results)) {
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment