Passed
Pull Request — master (#329)
by Mirko
07:45
created
htdocs/util/watchlist/runwatch.php 1 patch
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -484,6 +484,9 @@  discard block
 block discarded – undo
484 484
     );
485 485
 }
486 486
 
487
+/**
488
+ * @param string $watchtext
489
+ */
487 490
 function insert_maintenance_flags($rLog, $language, $watchtext)
488 491
 {
489 492
     global $translate;
@@ -510,6 +513,9 @@  discard block
 block discarded – undo
510 513
     return mb_ereg_replace('{maintenance_flags}', $flagtext, $watchtext);
511 514
 }
512 515
 
516
+/**
517
+ * @param string $domain
518
+ */
513 519
 function is_existent_maildomain($domain)
514 520
 {
515 521
     $smtp_serverlist = [];
Please login to merge, or discard this patch.
htdocs/util2/cron/modules/geokrety.class.php 2 patches
Doc Comments   +32 added lines patch added patch discarded remove patch
@@ -61,6 +61,10 @@  discard block
 block discarded – undo
61 61
 
62 62
     /* remove given file
63 63
      */
64
+
65
+    /**
66
+     * @param string $file
67
+     */
64 68
     public function removeXML($file)
65 69
     {
66 70
         @unlink($file);
@@ -68,6 +72,10 @@  discard block
 block discarded – undo
68 72
 
69 73
     /* import the given XML file
70 74
      */
75
+
76
+    /**
77
+     * @param string $file
78
+     */
71 79
     public function importXML($file)
72 80
     {
73 81
         global $opt;
@@ -124,6 +132,9 @@  discard block
 block discarded – undo
124 132
         setSysConfig('geokrety_lastupdate', date($opt['db']['dateformat'], strtotime($startupdate)));
125 133
     }
126 134
 
135
+    /**
136
+     * @param DOMNode $element
137
+     */
127 138
     public function importGeoKret($element)
128 139
     {
129 140
         global $opt;
@@ -204,6 +215,9 @@  discard block
 block discarded – undo
204 215
     }
205 216
 
206 217
 
218
+    /**
219
+     * @param DOMNode $element
220
+     */
207 221
     public function importMove($element)
208 222
     {
209 223
         global $opt;
@@ -292,6 +306,9 @@  discard block
 block discarded – undo
292 306
     }
293 307
 
294 308
 
309
+    /**
310
+     * @param integer $id
311
+     */
295 312
     public function checkGeoKretType($id, $name)
296 313
     {
297 314
         sql(
@@ -302,6 +319,9 @@  discard block
 block discarded – undo
302 319
     }
303 320
 
304 321
 
322
+    /**
323
+     * @param integer $id
324
+     */
305 325
     public function checkUser($id, $name)
306 326
     {
307 327
         if ($id == 0) {
@@ -312,6 +332,9 @@  discard block
 block discarded – undo
312 332
     }
313 333
 
314 334
 
335
+    /**
336
+     * @param integer $id
337
+     */
315 338
     public function checkMoveType($id, $name)
316 339
     {
317 340
         sql(
@@ -322,6 +345,9 @@  discard block
 block discarded – undo
322 345
     }
323 346
 
324 347
 
348
+    /**
349
+     * @param string $element
350
+     */
325 351
     public function GetNodeValue(&$domnode, $element)
326 352
     {
327 353
         $subnode = $domnode->getElementsByTagName($element);
@@ -333,6 +359,12 @@  discard block
 block discarded – undo
333 359
     }
334 360
 
335 361
 
362
+    /**
363
+     * @param string $element
364
+     * @param string $attr
365
+     *
366
+     * @return string
367
+     */
336 368
     public function GetNodeAttribute(&$domnode, $element, $attr)
337 369
     {
338 370
         $subnode = $domnode->getElementsByTagName($element);
Please login to merge, or discard this patch.
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
                         break;
116 116
                 }
117 117
 
118
-                $nRecordsCount ++;
118
+                $nRecordsCount++;
119 119
             }
120 120
         } while ($xr->next());
121 121
 
@@ -253,7 +253,7 @@  discard block
 block discarded – undo
253 253
         $waypoints = $element->getElementsByTagName('waypoints');
254 254
         if ($waypoints->length > 0) {
255 255
             $wpItems = $waypoints->item(0)->getElementsByTagName('waypoint');
256
-            for ($i = 0; $i < $wpItems->length; $i ++) {
256
+            for ($i = 0; $i < $wpItems->length; $i++) {
257 257
                 $wp = mb_trim($wpItems->item($i)->nodeValue);
258 258
                 if ($wp != '') {
259 259
                     sql("INSERT INTO `gk_move_waypoint` (`id`, `wp`) VALUES ('&1', '&2')", $id, $wp);
@@ -285,7 +285,7 @@  discard block
 block discarded – undo
285 285
                 WHERE `id`='&2' AND `wp`!=''",
286 286
                 $gkid,
287 287
                 $r['id']
288
-            );  // "late log" bugfix: replaced $id paramter by $r['id']
288
+            ); // "late log" bugfix: replaced $id paramter by $r['id']
289 289
         } else {
290 290
             // do nothing
291 291
         }
Please login to merge, or discard this patch.
htdocs/util2/cron/modules/sitemaps.class.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -61,6 +61,9 @@
 block discarded – undo
61 61
         $this->ping_searchengine('http://www.bing.com/webmaster/ping.aspx?siteMap=' . $url);
62 62
     }
63 63
 
64
+    /**
65
+     * @param string $url
66
+     */
64 67
     public function ping_searchengine($url)
65 68
     {
66 69
         $curl = curl_init($url);
Please login to merge, or discard this patch.
htdocs/xml/ocxml11.php 2 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -368,6 +368,9 @@
 block discarded – undo
368 368
 /* end parameter reading */
369 369
 
370 370
 
371
+/**
372
+ * @param integer $sessionid
373
+ */
371 374
 function outputXmlFile($sessionid, $filenr, $bXmlDecl, $bOcXmlTag, $bDocType, $ziptype)
372 375
 {
373 376
     global $zip_basedir, $zip_wwwdir, $sDateformat, $sDateshort, $t1, $t2, $t3, $safemode_zip, $safemode_zip, $sCharset, $bAttrlist;
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -438,7 +438,7 @@
 block discarded – undo
438 438
     $objecttypes['3'] = 'cachedesc';
439 439
     $objecttypes['1'] = 'cachelog';
440 440
     $objecttypes['6'] = 'picture';
441
-    $objecttypes['8'] = 'cachelist';    // not implemented yet
441
+    $objecttypes['8'] = 'cachelist'; // not implemented yet
442 442
 
443 443
     /* end now a few dynamically loaded constants */
444 444
 
Please login to merge, or discard this patch.
local/devel/find_unicode_boms.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -39,6 +39,9 @@
 block discarded – undo
39 39
 }
40 40
 
41 41
 
42
+/**
43
+ * @param string $path
44
+ */
42 45
 function testforbom($path)
43 46
 {
44 47
     $filestart = file_get_contents($path, false, null, 0, 2);
Please login to merge, or discard this patch.
local/ocxml11client/index.php 2 patches
Doc Comments   +8 added lines patch added patch discarded remove patch
@@ -1281,11 +1281,19 @@
 block discarded – undo
1281 1281
     }
1282 1282
 }
1283 1283
 
1284
+/**
1285
+ * @param string $recordtype
1286
+ * @param string $info
1287
+ */
1284 1288
 function importError($recordtype, $uuid, $r, $info)
1285 1289
 {
1286 1290
     echo 'error: ' . $recordtype . ' (' . $uuid . '): ' . $info . "\n";
1287 1291
 }
1288 1292
 
1293
+/**
1294
+ * @param string $recordtype
1295
+ * @param string $info
1296
+ */
1289 1297
 function importWarn($recordtype, $uuid, $r, $info)
1290 1298
 {
1291 1299
     echo 'warn: ' . $recordtype . ' (' . $uuid . '): ' . $info . "\n";
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
     $nFileNr = 0;
68 68
     $rs = sql('SELECT `id`, `url` FROM `pictures` WHERE `local`=0');
69 69
     while ($r = sql_fetch_array($rs)) {
70
-        $nFileNr ++;
70
+        $nFileNr++;
71 71
         $fileparts = mb_split('/', $r['url']);
72 72
         $filename = $fileparts[count($fileparts) - 1];
73 73
 
@@ -237,7 +237,7 @@  discard block
 block discarded – undo
237 237
             exit;
238 238
         }
239 239
 
240
-        for ($i = 1; $i <= $filescount; $i ++) {
240
+        for ($i = 1; $i <= $filescount; $i++) {
241 241
             echo "Download Paket: " . $i . ' von ' . $filescount . "\n";
242 242
 
243 243
             $fileurl = $opt['url_getsession'];
@@ -411,11 +411,11 @@  discard block
 block discarded – undo
411 411
                             if ($sSubElement != '') {
412 412
                                 // vorheriges element zuerst schlißen
413 413
                                 $sSubElement = '';
414
-                                $nRecursionLevel --;
414
+                                $nRecursionLevel--;
415 415
                             }
416 416
 
417 417
                             $sSubElement = mb_strtoupper($xmlReader->name);
418
-                            $nRecursionLevel ++;
418
+                            $nRecursionLevel++;
419 419
 
420 420
                             // attribute auslesen
421 421
                             if ($xmlReader->moveToFirstAttribute()) {
@@ -432,7 +432,7 @@  discard block
 block discarded – undo
432 432
                         } else {
433 433
                             if ($xmlReader->nodeType == XMLReader::END_ELEMENT) {
434 434
                                 $sSubElement = '';
435
-                                $nRecursionLevel --;
435
+                                $nRecursionLevel--;
436 436
                             }
437 437
                         }
438 438
                     }
Please login to merge, or discard this patch.
local/ocxml11client/xml2array.inc.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -26,6 +26,9 @@
 block discarded – undo
26 26
         $this->stack_ref =& $this->stack[count($this->stack) - 1];
27 27
     }
28 28
 
29
+    /**
30
+     * @param false|string $strInputXML
31
+     */
29 32
     public function parse($strInputXML)
30 33
     {
31 34
 
Please login to merge, or discard this patch.
htdocs/editdesc.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -21,8 +21,8 @@  discard block
 block discarded – undo
21 21
     // check for old-style parameters
22 22
     if (isset($_REQUEST['cacheid']) && isset($_REQUEST['desclang']) && !isset($_REQUEST['descid']))  // Ocprop
23 23
     {
24
-        $cache_id = $_REQUEST['cacheid'];  // Ocprop
25
-        $desc_lang = $_REQUEST['desclang'];  // Ocprop
24
+        $cache_id = $_REQUEST['cacheid']; // Ocprop
25
+        $desc_lang = $_REQUEST['desclang']; // Ocprop
26 26
 
27 27
         $rs = sql("SELECT `id` FROM `cache_desc` WHERE `cache_id`='&1' AND `language`='&2'", $cache_id, $desc_lang);
28 28
         if (mysql_num_rows($rs) == 1) {
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
                 if (isset($_POST['post']))  // Ocprop
91 91
                 {
92 92
                     //here we read all used information from the form if submitted
93
-                    $descMode = isset($_POST['descMode']) ? $_POST['descMode'] + 0 : 1;  // Ocprop
93
+                    $descMode = isset($_POST['descMode']) ? $_POST['descMode'] + 0 : 1; // Ocprop
94 94
 
95 95
                     // fuer alte Versionen von OCProp
96 96
                     if (isset($_POST['submit']) && !isset($_POST['version2'])) {
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
                         $oldDescMode = $descMode;
124 124
                     }
125 125
 
126
-                    $short_desc = $_POST['short_desc'];  // Ocprop
126
+                    $short_desc = $_POST['short_desc']; // Ocprop
127 127
                     $hint = htmlspecialchars($_POST['hints'], ENT_COMPAT, 'UTF-8');
128 128
                     $desclang = $_POST['desclang'];
129 129
                     $show_all_langs = isset($_POST['show_all_langs_value']) ? $_POST['show_all_langs_value'] : 0;
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
                     }
139 139
 
140 140
                     // Text from textarea
141
-                    $desc = $_POST['desc'];  // Ocprop
141
+                    $desc = $_POST['desc']; // Ocprop
142 142
 
143 143
                     // fuer alte Versionen von OCProp
144 144
                     if (isset($_POST['submit']) && !isset($_POST['version2'])) {
@@ -297,7 +297,7 @@  discard block
 block discarded – undo
297 297
                 tpl_set_var('desclang', htmlspecialchars($desc_lang, ENT_COMPAT, 'UTF-8'));
298 298
                 tpl_set_var('desclang_name', htmlspecialchars(db_LanguageFromShort($desc_lang), ENT_COMPAT, 'UTF-8'));
299 299
                 tpl_set_var('cachename', htmlspecialchars($desc_record['name'], ENT_COMPAT, 'UTF-8'));
300
-                tpl_set_var('reset', $reset);  // obsolete
300
+                tpl_set_var('reset', $reset); // obsolete
301 301
                 tpl_set_var('submit', $submit);
302 302
 
303 303
                 // Text / normal HTML / HTML editor
Please login to merge, or discard this patch.
htdocs/okapi_settings.php 2 patches
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
         'DATA_LICENSE_URL' => $opt['page']['absolute_url'] . $opt['logic']['license']['terms'],
34 34
         'DEBUG'            => ($opt['debug'] & DEBUG_DEVELOPER != 0),
35 35
         'DEBUG_PREVENT_SEMAPHORES'
36
-                           => !$opt['php']['semaphores'],  # not available on old developer system
36
+                            => !$opt['php']['semaphores'],  # not available on old developer system
37 37
         'DB_SERVER'        => $opt['db']['servername'],
38 38
         'DB_NAME'          => $opt['db']['placeholder']['db'],
39 39
         'DB_USERNAME'      => $opt['db']['username'],
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
         'OC_NODE_ID'       => $opt['logic']['node']['id'],
55 55
         'OC_COOKIE_NAME'   => $opt['session']['cookiename'] . 'data',
56 56
         'OCDE_HTML_PURIFIER_SETTINGS'
57
-                           => $opt['html_purifier'],
57
+                            => $opt['html_purifier'],
58 58
         'GITHUB_ACCESS_TOKEN' => $opt['okapi']['github_access_token'],
59 59
     );
60 60
 }
Please login to merge, or discard this patch.
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -16,7 +16,7 @@  discard block
 block discarded – undo
16 16
     # [3] http://code.google.com/p/opencaching-api/issues/detail?id=132
17 17
 
18 18
     $opt['rootpath'] = $GLOBALS['rootpath'];
19
-    require $opt['rootpath'] . 'lib2/const.inc.php';   # (into the *local* scope!)
19
+    require $opt['rootpath'] . 'lib2/const.inc.php'; # (into the *local* scope!)
20 20
     require $opt['rootpath'] . 'config2/settings-dist.inc.php';
21 21
     require $opt['rootpath'] . 'config2/settings.inc.php';
22 22
     
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
 
25 25
         # Settings which ARE NOT present in settings.inc.php:
26 26
 
27
-        'OC_BRANCH' => 'oc.de',  # Tell OKAPI to work in "OCDE mode".
27
+        'OC_BRANCH' => 'oc.de', # Tell OKAPI to work in "OCDE mode".
28 28
 
29 29
         # Settings which ARE present in settings.inc.php:
30 30
 
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
         'DATA_LICENSE_URL' => $opt['page']['absolute_url'] . $opt['logic']['license']['terms'],
34 34
         'DEBUG'            => ($opt['debug'] & DEBUG_DEVELOPER != 0),
35 35
         'DEBUG_PREVENT_SEMAPHORES'
36
-                           => !$opt['php']['semaphores'],  # not available on old developer system
36
+                           => !$opt['php']['semaphores'], # not available on old developer system
37 37
         'DB_SERVER'        => $opt['db']['servername'],
38 38
         'DB_NAME'          => $opt['db']['placeholder']['db'],
39 39
         'DB_USERNAME'      => $opt['db']['username'],
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
         'IMAGES_DIR'       => rtrim($opt['logic']['pictures']['dir'], '/'),
50 50
         'IMAGES_URL'       => rtrim($opt['logic']['pictures']['url'], '/') . '/',
51 51
         'IMAGE_MAX_UPLOAD_SIZE' => 2 * $opt['logic']['pictures']['maxsize'],
52
-        'IMAGE_MAX_PIXEL_COUNT' => 786432,  # 1024 x 768; TODO: move PICTURE_MAX_LONG_SIDE to settings
52
+        'IMAGE_MAX_PIXEL_COUNT' => 786432, # 1024 x 768; TODO: move PICTURE_MAX_LONG_SIDE to settings
53 53
         'SITE_LOGO'        => $opt['page']['absolute_url'] . 'resource2/' . $opt['template']['default']['style'] . '/images/oclogo/oc_logo_alpha3.png',
54 54
         'OC_NODE_ID'       => $opt['logic']['node']['id'],
55 55
         'OC_COOKIE_NAME'   => $opt['session']['cookiename'] . 'data',
Please login to merge, or discard this patch.