Completed
Push — next ( 7bd953...6fc1ab )
by Thomas
18s queued 11s
created
htdocs/search.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -88,7 +88,7 @@  discard block
 block discarded – undo
88 88
 $load_query = false;
89 89
 $show_lastsearchbutton = true;
90 90
 
91
-$list_caches = isset($_REQUEST['addCache']) &&  $_REQUEST['addCache'] >= 1 ? $_REQUEST['addCache'] : '';
91
+$list_caches = isset($_REQUEST['addCache']) && $_REQUEST['addCache'] >= 1 ? $_REQUEST['addCache'] : '';
92 92
 $added_waypoints = 0;
93 93
 
94 94
 if (isset($_REQUEST['queryid']) || isset($_REQUEST['showresult'])) {  // Ocprop: showresult, queryid
@@ -255,20 +255,20 @@  discard block
 block discarded – undo
255 255
     }
256 256
 
257 257
     // get the search options parameters and store them in the queries table (to view "the next page")
258
-    $options['f_userowner'] = isset($_REQUEST['f_userowner']) ? (int) $_REQUEST['f_userowner'] : 0; // Ocprop
259
-    $options['f_userfound'] = isset($_REQUEST['f_userfound']) ? (int) $_REQUEST['f_userfound'] : 0; // Ocprop
260
-    $options['f_unpublished'] = isset($_REQUEST['f_unpublished']) ? (int) $_REQUEST['f_unpublished'] : 0;
261
-    $options['f_disabled'] = isset($_REQUEST['f_disabled']) ? (int) $_REQUEST['f_disabled'] : 0;
262
-    $options['f_inactive'] = isset($_REQUEST['f_inactive']) ? (int) $_REQUEST['f_inactive'] : 1; // Ocprop
258
+    $options['f_userowner'] = isset($_REQUEST['f_userowner']) ? (int)$_REQUEST['f_userowner'] : 0; // Ocprop
259
+    $options['f_userfound'] = isset($_REQUEST['f_userfound']) ? (int)$_REQUEST['f_userfound'] : 0; // Ocprop
260
+    $options['f_unpublished'] = isset($_REQUEST['f_unpublished']) ? (int)$_REQUEST['f_unpublished'] : 0;
261
+    $options['f_disabled'] = isset($_REQUEST['f_disabled']) ? (int)$_REQUEST['f_disabled'] : 0;
262
+    $options['f_inactive'] = isset($_REQUEST['f_inactive']) ? (int)$_REQUEST['f_inactive'] : 1; // Ocprop
263 263
     // f_inactive formerly was used for both, archived and disabled caches.
264 264
     // After adding the separate f_disabled option, it is used only for archived
265 265
     // caches, but keeps its name for compatibility with existing stored or
266 266
     // external searches.
267
-    $options['f_ignored'] = isset($_REQUEST['f_ignored']) ? (int) $_REQUEST['f_ignored'] : 1;
268
-    $options['f_otherPlatforms'] = isset($_REQUEST['f_otherPlatforms']) ? (int) $_REQUEST['f_otherPlatforms'] : 0;
269
-    $options['f_geokrets'] = isset($_REQUEST['f_geokrets']) ? (int) $_REQUEST['f_geokrets'] : 0;
270
-    $options['expert'] = isset($_REQUEST['expert']) ? (int) $_REQUEST['expert'] : 0; // Ocprop: 0
271
-    $options['showresult'] = isset($_REQUEST['showresult']) ? (int) $_REQUEST['showresult'] : 0;
267
+    $options['f_ignored'] = isset($_REQUEST['f_ignored']) ? (int)$_REQUEST['f_ignored'] : 1;
268
+    $options['f_otherPlatforms'] = isset($_REQUEST['f_otherPlatforms']) ? (int)$_REQUEST['f_otherPlatforms'] : 0;
269
+    $options['f_geokrets'] = isset($_REQUEST['f_geokrets']) ? (int)$_REQUEST['f_geokrets'] : 0;
270
+    $options['expert'] = isset($_REQUEST['expert']) ? (int)$_REQUEST['expert'] : 0; // Ocprop: 0
271
+    $options['showresult'] = isset($_REQUEST['showresult']) ? (int)$_REQUEST['showresult'] : 0;
272 272
     $options['output'] = isset($_REQUEST['output']) ? $_REQUEST['output'] : 'HTML'; // Ocprop: HTML
273 273
     $options['bbox'] = isset($_REQUEST['bbox']) ? $_REQUEST['bbox'] : false;
274 274
 
@@ -322,7 +322,7 @@  discard block
 block discarded – undo
322 322
     } elseif (isset($_REQUEST['searchbyowner'])) { // Ocprop
323 323
         $options['searchtype'] = 'byowner';
324 324
 
325
-        $options['ownerid'] = isset($_REQUEST['ownerid']) ? (int) $_REQUEST['ownerid'] : 0;
325
+        $options['ownerid'] = isset($_REQUEST['ownerid']) ? (int)$_REQUEST['ownerid'] : 0;
326 326
         $options['owner'] = isset($_REQUEST['owner']) ? stripslashes($_REQUEST['owner']) : '';
327 327
 
328 328
         if (isset($options['owner'])) {
@@ -338,7 +338,7 @@  discard block
 block discarded – undo
338 338
     } elseif (isset($_REQUEST['searchbyfinder'])) { // Ocprop
339 339
         $options['searchtype'] = 'byfinder';
340 340
 
341
-        $options['finderid'] = isset($_REQUEST['finderid']) ? (int) $_REQUEST['finderid'] : 0;
341
+        $options['finderid'] = isset($_REQUEST['finderid']) ? (int)$_REQUEST['finderid'] : 0;
342 342
         $options['finder'] = isset($_REQUEST['finder']) ? stripslashes($_REQUEST['finder']) : '';
343 343
         $options['logtype'] = isset($_REQUEST['logtype']) ? $_REQUEST['logtype'] : '1,7'; // Ocprop
344 344
 
@@ -393,7 +393,7 @@  discard block
 block discarded – undo
393 393
             $options['lon_min'] = isset($_REQUEST['lon_min']) ? $_REQUEST['lon_min'] : 0;
394 394
         }
395 395
 
396
-        $options['distance'] = isset($_REQUEST['distance']) ? (int) $_REQUEST['distance'] : 0;
396
+        $options['distance'] = isset($_REQUEST['distance']) ? (int)$_REQUEST['distance'] : 0;
397 397
     } elseif (isset($_REQUEST['searchbyfulltext'])) {
398 398
         $options['searchtype'] = 'byfulltext';
399 399
 
@@ -1297,11 +1297,11 @@  discard block
 block discarded – undo
1297 1297
 
1298 1298
         //add selected caches to selected cachelist
1299 1299
         if (isset($_REQUEST['addToList']) && isset($_REQUEST['addCache']) && isset($_REQUEST['selectCachelist'])) {
1300
-            $list_caches_= $_REQUEST['addToList'];
1300
+            $list_caches_ = $_REQUEST['addToList'];
1301 1301
             $added_waypoints = addToList($list_caches);
1302
-            $addCachelist= cachelist::getListById((int) $_REQUEST['selectCachelist']); // null for invalid ID
1302
+            $addCachelist = cachelist::getListById((int)$_REQUEST['selectCachelist']); // null for invalid ID
1303 1303
         } elseif (isset($_REQUEST['addToList'])) {
1304
-            $addCachelist= cachelist::getListById((int) $_REQUEST['selectCachelist']); // null for invalid ID
1304
+            $addCachelist = cachelist::getListById((int)$_REQUEST['selectCachelist']); // null for invalid ID
1305 1305
             $error_addCaches = true;
1306 1306
         }
1307 1307
 
@@ -1773,7 +1773,7 @@  discard block
 block discarded – undo
1773 1773
     $tpl->assign('searchtype_byname', $options['searchtype'] == 'byname');
1774 1774
 
1775 1775
     // distance
1776
-    $tpl->assign('distance', isset($options['distance']) ? (int) $options['distance'] : DEFAULT_SEARCH_DISTANCE);
1776
+    $tpl->assign('distance', isset($options['distance']) ? (int)$options['distance'] : DEFAULT_SEARCH_DISTANCE);
1777 1777
 
1778 1778
     if (!isset($options['unit'])) {
1779 1779
         $options['unit'] = DEFAULT_DISTANCE_UNIT;
Please login to merge, or discard this patch.