Completed
Push — master ( a21b67...ec1681 )
by Michael
02:43
created
class/pear/Calendar/Engine/PearDate.php 2 patches
Doc Comments   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -192,6 +192,9 @@  discard block
 block discarded – undo
192 192
      * @param int &$h hour   (13)
193 193
      * @param int &$i minute (34)
194 194
      * @param int &$s second (53)
195
+     * @param integer $y
196
+     * @param integer $m
197
+     * @param integer $d
195 198
      */
196 199
     public function adjustDate(&$y, &$m, &$d, &$h, &$i, &$s)
197 200
     {
@@ -407,7 +410,7 @@  discard block
 block discarded – undo
407 410
      * @param int $m month (9)
408 411
      * @param int $d day (4)
409 412
      *
410
-     * @return array (0, 1, 2, 3, 4, 5, 6) 1 = Monday
413
+     * @return integer[] (0, 1, 2, 3, 4, 5, 6) 1 = Monday
411 414
      */
412 415
     public function getWeekDays($y = null, $m = null, $d = null)
413 416
     {
@@ -476,7 +479,7 @@  discard block
 block discarded – undo
476 479
     /**
477 480
      * Checks if the given day is the current day.
478 481
      *
479
-     * @param mixed $stamp Any timestamp format recognized by Pear::Date
482
+     * @param string $stamp Any timestamp format recognized by Pear::Date
480 483
      *
481 484
      * @return bool
482 485
      */
Please login to merge, or discard this patch.
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
 /**
41 41
  * Load PEAR::Date class.
42 42
  */
43
-require_once __DIR__ . '/Date.php';
43
+require_once __DIR__.'/Date.php';
44 44
 
45 45
 /**
46 46
  * Performs calendar calculations based on the PEAR::Date class
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
     {
87 87
         $date = self::stampCollection($stamp);
88 88
 
89
-        return (int)$date->year;
89
+        return (int) $date->year;
90 90
     }
91 91
 
92 92
     /**
@@ -100,7 +100,7 @@  discard block
 block discarded – undo
100 100
     {
101 101
         $date = self::stampCollection($stamp);
102 102
 
103
-        return (int)$date->month;
103
+        return (int) $date->month;
104 104
     }
105 105
 
106 106
     /**
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
     {
115 115
         $date = self::stampCollection($stamp);
116 116
 
117
-        return (int)$date->day;
117
+        return (int) $date->day;
118 118
     }
119 119
 
120 120
     /**
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
     {
129 129
         $date = self::stampCollection($stamp);
130 130
 
131
-        return (int)$date->hour;
131
+        return (int) $date->hour;
132 132
     }
133 133
 
134 134
     /**
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
     {
143 143
         $date = self::stampCollection($stamp);
144 144
 
145
-        return (int)$date->minute;
145
+        return (int) $date->minute;
146 146
     }
147 147
 
148 148
     /**
@@ -156,7 +156,7 @@  discard block
 block discarded – undo
156 156
     {
157 157
         $date = self::stampCollection($stamp);
158 158
 
159
-        return (int)$date->second;
159
+        return (int) $date->second;
160 160
     }
161 161
 
162 162
     /**
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
     {
176 176
         $r = array();
177 177
         self::adjustDate($y, $m, $d, $h, $i, $s);
178
-        $key = $y . $m . $d . $h . $i . $s;
178
+        $key = $y.$m.$d.$h.$i.$s;
179 179
         if (!isset($r[$key])) {
180 180
             $r[$key] = sprintf('%04d-%02d-%02d %02d:%02d:%02d', $y, $m, $d, $h, $i, $s);
181 181
         }
@@ -286,7 +286,7 @@  discard block
 block discarded – undo
286 286
      */
287 287
     public function getDaysInMonth($y, $m)
288 288
     {
289
-        return (int)Date_Calc::daysInMonth($m, $y);
289
+        return (int) Date_Calc::daysInMonth($m, $y);
290 290
     }
291 291
 
292 292
     /**
@@ -300,7 +300,7 @@  discard block
 block discarded – undo
300 300
      */
301 301
     public function getFirstDayInMonth($y, $m)
302 302
     {
303
-        return (int)Date_Calc::dayOfWeek(1, $m, $y);
303
+        return (int) Date_Calc::dayOfWeek(1, $m, $y);
304 304
     }
305 305
 
306 306
     /**
@@ -347,7 +347,7 @@  discard block
 block discarded – undo
347 347
     public function getWeekNInMonth($y, $m, $d, $firstDay = 1)
348 348
     {
349 349
         $weekEnd     = ($firstDay == 0) ? $this->getDaysInWeek() - 1 : $firstDay - 1;
350
-        $end_of_week = (int)Date_Calc::nextDayOfWeek($weekEnd, 1, $m, $y, '%e', true);
350
+        $end_of_week = (int) Date_Calc::nextDayOfWeek($weekEnd, 1, $m, $y, '%e', true);
351 351
         $w           = 1;
352 352
         while ($d > $end_of_week) {
353 353
             ++$w;
@@ -381,7 +381,7 @@  discard block
 block discarded – undo
381 381
         }
382 382
         $daysInTheFirstWeek %= $this->getDaysInWeek();
383 383
 
384
-        return (int)(ceil(($this->getDaysInMonth($y, $m) - $daysInTheFirstWeek) / $this->getDaysInWeek()) + $weeks);
384
+        return (int) (ceil(($this->getDaysInMonth($y, $m) - $daysInTheFirstWeek) / $this->getDaysInWeek()) + $weeks);
385 385
     }
386 386
 
387 387
     /**
Please login to merge, or discard this patch.
class/pear/Calendar/Engine/UnixTS.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -363,7 +363,7 @@  discard block
 block discarded – undo
363 363
      * @param int $m month (9)
364 364
      * @param int $d day (4)
365 365
      *
366
-     * @return array (0,1,2,3,4,5,6) 1 = Monday
366
+     * @return integer[] (0,1,2,3,4,5,6) 1 = Monday
367 367
      */
368 368
     public function getWeekDays($y = null, $m = null, $d = null)
369 369
     {
@@ -432,7 +432,7 @@  discard block
 block discarded – undo
432 432
     /**
433 433
      * Checks if the given day is the current day.
434 434
      *
435
-     * @param mixed $stamp Any timestamp format recognized by Pear::Date
435
+     * @param integer $stamp Any timestamp format recognized by Pear::Date
436 436
      *
437 437
      * @return bool
438 438
      */
Please login to merge, or discard this patch.
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -95,7 +95,7 @@  discard block
 block discarded – undo
95 95
     {
96 96
         $date = self::stampCollection($stamp);
97 97
 
98
-        return (int)$date[0];
98
+        return (int) $date[0];
99 99
     }
100 100
 
101 101
     /**
@@ -109,7 +109,7 @@  discard block
 block discarded – undo
109 109
     {
110 110
         $date = self::stampCollection($stamp);
111 111
 
112
-        return (int)$date[1];
112
+        return (int) $date[1];
113 113
     }
114 114
 
115 115
     /**
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
     {
124 124
         $date = self::stampCollection($stamp);
125 125
 
126
-        return (int)$date[2];
126
+        return (int) $date[2];
127 127
     }
128 128
 
129 129
     /**
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
     {
138 138
         $date = self::stampCollection($stamp);
139 139
 
140
-        return (int)$date[3];
140
+        return (int) $date[3];
141 141
     }
142 142
 
143 143
     /**
@@ -151,7 +151,7 @@  discard block
 block discarded – undo
151 151
     {
152 152
         $date = self::stampCollection($stamp);
153 153
 
154
-        return (int)$date[4];
154
+        return (int) $date[4];
155 155
     }
156 156
 
157 157
     /**
@@ -165,7 +165,7 @@  discard block
 block discarded – undo
165 165
     {
166 166
         $date = self::stampCollection($stamp);
167 167
 
168
-        return (int)$date[5];
168
+        return (int) $date[5];
169 169
     }
170 170
 
171 171
     /**
@@ -336,7 +336,7 @@  discard block
 block discarded – undo
336 336
         }
337 337
         $daysInTheFirstWeek %= $this->getDaysInWeek();
338 338
 
339
-        return (int)(ceil(($this->getDaysInMonth($y, $m) - $daysInTheFirstWeek) / $this->getDaysInWeek()) + $weeks);
339
+        return (int) (ceil(($this->getDaysInMonth($y, $m) - $daysInTheFirstWeek) / $this->getDaysInWeek()) + $weeks);
340 340
     }
341 341
 
342 342
     /**
Please login to merge, or discard this patch.
class/pear/Calendar/Table/Helper.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -171,7 +171,7 @@
 block discarded – undo
171 171
     /**
172 172
      * Returns the first day of the month.
173 173
      *
174
-     * @return int
174
+     * @return string
175 175
      *
176 176
      * @see    Calendar_Engine_Interface::getFirstDayOfWeek()
177 177
      */
Please login to merge, or discard this patch.
class/pear/Calendar/Util/Uri.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -137,7 +137,7 @@  discard block
 block discarded – undo
137 137
     /**
138 138
      * Gets the URI string for the previous calendar unit.
139 139
      *
140
-     * @param object $Calendar subclassed from Calendar e.g. Calendar_Month
140
+     * @param Calendar_Decorator_Uri $Calendar subclassed from Calendar e.g. Calendar_Month
141 141
      * @param string $unit     calendar  unit (year|month|week|day|hour|minute|second)
142 142
      *
143 143
      * @return string
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
     /**
170 170
      * Gets the URI string for the next calendar unit.
171 171
      *
172
-     * @param object $Calendar subclassed from Calendar e.g. Calendar_Month
172
+     * @param Calendar_Decorator_Uri $Calendar subclassed from Calendar e.g. Calendar_Month
173 173
      * @param string $unit     calendar unit (year|month|week|day|hour|minute|second)
174 174
      *
175 175
      * @return string
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
      */
145 145
     public function prev($Calendar, $unit)
146 146
     {
147
-        $method = 'prev' . $unit;
147
+        $method = 'prev'.$unit;
148 148
         $stamp  = $Calendar->{$method}('timestamp');
149 149
 
150 150
         return $this->buildUriString($Calendar, $method, $stamp);
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
      */
161 161
     public function this($Calendar, $unit)
162 162
     {
163
-        $method = 'this' . $unit;
163
+        $method = 'this'.$unit;
164 164
         $stamp  = $Calendar->{$method}('timestamp');
165 165
 
166 166
         return $this->buildUriString($Calendar, $method, $stamp);
@@ -176,7 +176,7 @@  discard block
 block discarded – undo
176 176
      */
177 177
     public function next($Calendar, $unit)
178 178
     {
179
-        $method = 'next' . $unit;
179
+        $method = 'next'.$unit;
180 180
         $stamp  = $Calendar->{$method}('timestamp');
181 181
 
182 182
         return $this->buildUriString($Calendar, $method, $stamp);
@@ -197,10 +197,10 @@  discard block
 block discarded – undo
197 197
         $cE        = $Calendar->getEngine();
198 198
         $separator = '';
199 199
         foreach ($this->uris as $unit => $uri) {
200
-            $call      = 'stampTo' . $unit;
200
+            $call = 'stampTo'.$unit;
201 201
             $uriString .= $separator;
202 202
             if (!$this->scalar) {
203
-                $uriString .= $uri . '=';
203
+                $uriString .= $uri.'=';
204 204
             }
205 205
             $uriString .= $cE->{$call}($stamp);
206 206
             $separator = $this->separator;
Please login to merge, or discard this patch.
class/time.php 2 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -38,7 +38,7 @@  discard block
 block discarded – undo
38 38
     }
39 39
 
40 40
     /**
41
-     * @param $id
41
+     * @param integer $id
42 42
      *
43 43
      * @return mixed
44 44
      */
@@ -86,7 +86,7 @@  discard block
 block discarded – undo
86 86
      * @param $format
87 87
      * @param $timestamp
88 88
      *
89
-     * @return mixed
89
+     * @return string
90 90
      */
91 91
     public function getFormatedDate($format, $timestamp)
92 92
     {
Please login to merge, or discard this patch.
Spacing   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@  discard block
 block discarded – undo
2 2
 
3 3
 // defined('XOOPS_ROOT_PATH') || exit('XOOPS root path not defined');
4 4
 
5
-require_once XOOPS_ROOT_PATH . '/language/' . $GLOBALS['xoopsConfig']['language'] . '/calendar.php';
5
+require_once XOOPS_ROOT_PATH.'/language/'.$GLOBALS['xoopsConfig']['language'].'/calendar.php';
6 6
 
7 7
 $moduleDirName = basename(dirname(__DIR__));
8 8
 xoops_loadLanguage('main', $moduleDirName);
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
      */
91 91
     public function getFormatedDate($format, $timestamp)
92 92
     {
93
-        $patterns     = array(
93
+        $patterns = array(
94 94
             '/January/',
95 95
             '/February/',
96 96
             '/March/',
@@ -143,18 +143,18 @@  discard block
 block discarded – undo
143 143
             _CAL_OCTOBER,
144 144
             _CAL_NOVEMBER,
145 145
             _CAL_DECEMBER,
146
-            substr(_CAL_JANUARY, 0, 3) . ' ',
147
-            substr(_CAL_FEBRUARY, 0, 3) . ' ',
148
-            substr(_CAL_MARCH, 0, 3) . ' ',
149
-            substr(_CAL_APRIL, 0, 3) . ' ',
150
-            substr(_CAL_MAY, 0, 3) . ' ',
151
-            substr(_CAL_JUNE, 0, 3) . ' ',
152
-            substr(_CAL_JULY, 0, 3) . ' ',
153
-            substr(_CAL_AUGUST, 0, 3) . ' ',
154
-            substr(_CAL_SEPTEMBER, 0, 3) . ' ',
155
-            substr(_CAL_OCTOBER, 0, 3) . ' ',
156
-            substr(_CAL_NOVEMBER, 0, 3) . ' ',
157
-            substr(_CAL_DECEMBER, 0, 3) . ' ',
146
+            substr(_CAL_JANUARY, 0, 3).' ',
147
+            substr(_CAL_FEBRUARY, 0, 3).' ',
148
+            substr(_CAL_MARCH, 0, 3).' ',
149
+            substr(_CAL_APRIL, 0, 3).' ',
150
+            substr(_CAL_MAY, 0, 3).' ',
151
+            substr(_CAL_JUNE, 0, 3).' ',
152
+            substr(_CAL_JULY, 0, 3).' ',
153
+            substr(_CAL_AUGUST, 0, 3).' ',
154
+            substr(_CAL_SEPTEMBER, 0, 3).' ',
155
+            substr(_CAL_OCTOBER, 0, 3).' ',
156
+            substr(_CAL_NOVEMBER, 0, 3).' ',
157
+            substr(_CAL_DECEMBER, 0, 3).' ',
158 158
             _CAL_SUNDAY,
159 159
             _CAL_MONDAY,
160 160
             _CAL_TUESDAY,
@@ -162,13 +162,13 @@  discard block
 block discarded – undo
162 162
             _CAL_THURSDAY,
163 163
             _CAL_FRIDAY,
164 164
             _CAL_SATURDAY,
165
-            substr(_CAL_SUNDAY, 0, 3) . ' ',
166
-            substr(_CAL_MONDAY, 0, 3) . ' ',
167
-            substr(_CAL_TUESDAY, 0, 3) . ' ',
168
-            substr(_CAL_WEDNESDAY, 0, 3) . ' ',
169
-            substr(_CAL_THURSDAY, 0, 3) . ' ',
170
-            substr(_CAL_FRIDAY, 0, 3) . ' ',
171
-            substr(_CAL_SATURDAY, 0, 3) . ' ',
165
+            substr(_CAL_SUNDAY, 0, 3).' ',
166
+            substr(_CAL_MONDAY, 0, 3).' ',
167
+            substr(_CAL_TUESDAY, 0, 3).' ',
168
+            substr(_CAL_WEDNESDAY, 0, 3).' ',
169
+            substr(_CAL_THURSDAY, 0, 3).' ',
170
+            substr(_CAL_FRIDAY, 0, 3).' ',
171
+            substr(_CAL_SATURDAY, 0, 3).' ',
172 172
         );
173 173
 
174 174
         return preg_replace($patterns, $replacements, date($format, $timestamp));
@@ -210,7 +210,7 @@  discard block
 block discarded – undo
210 210
                 array_shift($eventOptions);
211 211
                 $day = '';
212 212
                 foreach ($eventOptions as $option) {
213
-                    $day .= ' ' . $daysName[$option] . ', ';
213
+                    $day .= ' '.$daysName[$option].', ';
214 214
                 }
215 215
                 $ret = sprintf(_MD_EXTCAL_RR_WEEKLY, $day, $interval);
216 216
 
@@ -329,7 +329,7 @@  discard block
 block discarded – undo
329 329
                 array_shift($eventOptions);
330 330
                 $month = '';
331 331
                 foreach ($eventOptions as $option) {
332
-                    $month .= ' ' . $monthName[$option] . ', ';
332
+                    $month .= ' '.$monthName[$option].', ';
333 333
                 }
334 334
                 $dayString = $day;
335 335
                 if (array_key_exists($day, $monthDays)) {
Please login to merge, or discard this patch.
include/agenda_fnc.php 2 patches
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -38,6 +38,9 @@  discard block
 block discarded – undo
38 38
  * @return array
39 39
  */
40 40
 
41
+/**
42
+ * @param string $formatDate
43
+ */
41 44
 function agenda_getCanevas($ts, $hStart, $hEnd, $mPlage = 15, $nbJours = 1, $formatDate, $formatJour = 'H:i')
42 45
 {
43 46
     global $xoopsModuleConfig;
@@ -294,6 +297,9 @@  discard block
 block discarded – undo
294 297
  * @param $name
295 298
  * @return bool
296 299
  */
300
+/**
301
+ * @param string $name
302
+ */
297 303
 function ext_loadLanguage($name)
298 304
 {
299 305
     global $xoopsConfig;
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -18,8 +18,8 @@  discard block
 block discarded – undo
18 18
 define('_EXTCAL_FORMAT_AGENDA_KEYD', 'Y-m-d');
19 19
 define('_EXTCAL_FORMAT_AGENDA_KEYT', 'H:i');
20 20
 
21
-require_once __DIR__ . '/constantes.php';
22
-require_once __DIR__ . '/../class/utility.php';
21
+require_once __DIR__.'/constantes.php';
22
+require_once __DIR__.'/../class/utility.php';
23 23
 
24 24
 $moduleDirName = basename(dirname(__DIR__));
25 25
 xoops_loadLanguage('main', $moduleDirName);
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
         $tj[$kj]['dayWeek'] = date('w', $tsj);
72 72
         $tj[$kj]['jour']    = $jName[$tj[$kj]['dayWeek']]; //date('l', $tsj);
73 73
         if ($tj[$kj]['dayWeek'] == 0) {
74
-            $tj[$kj]['bg'] = "background='" . XOOPS_URL . "/modules/extcal/assets/images/trame.png'";
74
+            $tj[$kj]['bg'] = "background='".XOOPS_URL."/modules/extcal/assets/images/trame.png'";
75 75
         } else {
76 76
             $tj[$kj]['bg'] = '';
77 77
         }
@@ -151,16 +151,16 @@  discard block
 block discarded – undo
151 151
         $kd     = date(_EXTCAL_FORMAT_AGENDA_KEYD, $ts);
152 152
         $hour   = date('H', $ts);
153 153
         $minute = date('i', $ts);
154
-        $m      = (int)($minute / $mPlage) * $mPlage;
154
+        $m      = (int) ($minute / $mPlage) * $mPlage;
155 155
         //      echo "--->{$minute} / {$mPlage} = {$m}<br>";
156
-        $sMinute = (($m < 10) ? '0' . $m : $m);
156
+        $sMinute = (($m < 10) ? '0'.$m : $m);
157 157
         //$kt = date(_EXTCAL_FORMAT_AGENDA_KEYT, $ts);
158 158
         if ($hour < $hStart) {
159 159
             $kt = $tk0;
160 160
         } elseif ($hour >= ($hEnd + 1)) {
161 161
             $kt = $tk1;
162 162
         } else {
163
-            $kt = $hour . ':' . $sMinute;
163
+            $kt = $hour.':'.$sMinute;
164 164
         }
165 165
 
166 166
         $tAgenda[$kt]['jours'][$kd]['events'][] = $e;
@@ -309,7 +309,7 @@  discard block
 block discarded – undo
309 309
             return false;
310 310
     }
311 311
 
312
-    $file   = XOOPS_ROOT_PATH . '/language/' . $xoopsConfig['language'] . '/' . $f;
312
+    $file   = XOOPS_ROOT_PATH.'/language/'.$xoopsConfig['language'].'/'.$f;
313 313
     $prefix = (defined($name) ? '_MI' : '_MD');
314 314
     require_once $file;
315 315
 }
@@ -449,7 +449,7 @@  discard block
 block discarded – undo
449 449
     //    while (list($k, $v) = each($tNavBar)) {
450 450
     foreach ($tNavBar as $k => $v) {
451 451
         if (isset($tWeight[$k])) {
452
-            $ordre[] = (int)$tWeight[$k]; //ordre defini dans les option du module
452
+            $ordre[] = (int) $tWeight[$k]; //ordre defini dans les option du module
453 453
         } else {
454 454
             $ordre[] = $v['weight']; // ordre par defaut ddefini dans le tableau $tNavBar
455 455
         }
Please login to merge, or discard this patch.
include/mail_fnc.php 2 patches
Doc Comments   +6 added lines patch added patch discarded remove patch
@@ -194,6 +194,9 @@  discard block
 block discarded – undo
194 194
  * @param int    $mode
195 195
  * @param string $sep
196 196
  */
197
+/**
198
+ * @param string $mail_subject
199
+ */
197 200
 function extcal_SendMail(
198 201
     $destinataires,
199 202
     $mail_fromname,
@@ -280,6 +283,9 @@  discard block
 block discarded – undo
280 283
  *
281 284
  * @return string
282 285
  */
286
+/**
287
+ * @param integer $mode
288
+ */
283 289
 function extcal_getHeader($mode, $emailSender)
284 290
 {
285 291
     //mode = 0 pas d'entete
Please login to merge, or discard this patch.
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -20,11 +20,11 @@  discard block
 block discarded – undo
20 20
  * que la classe correspondante de la table a été générées avec classGenerator
21 21
  **/
22 22
 
23
-require_once __DIR__ . '/../../../class/uploader.php';
24
-require_once __DIR__ . '/../../../class/mail/phpmailer/class.phpmailer.php'; // First we require the PHPMailer libary in our script
25
-require_once __DIR__ . '/../class/utility.php';
26
-require_once __DIR__ . '/constantes.php';
27
-require_once __DIR__ . '/../../../class/template.php';
23
+require_once __DIR__.'/../../../class/uploader.php';
24
+require_once __DIR__.'/../../../class/mail/phpmailer/class.phpmailer.php'; // First we require the PHPMailer libary in our script
25
+require_once __DIR__.'/../class/utility.php';
26
+require_once __DIR__.'/constantes.php';
27
+require_once __DIR__.'/../../../class/template.php';
28 28
 
29 29
 /********************************************************************
30 30
  *
@@ -138,7 +138,7 @@  discard block
 block discarded – undo
138 138
     $action  = ''; //a voir   JJD
139 139
     $message = sprintf($tplMessage, $acteur['name']);
140 140
     //$subject .= ' (' . rand(1, 100) . ')';
141
-    $subject .= ' - ' . $acteur['name'];
141
+    $subject .= ' - '.$acteur['name'];
142 142
     //--------------------------------------------------------------
143 143
     //Chargement du template dans le dossier de langue
144 144
     //$f = _EXTCAL_PATH_LG . $xoopsConfig['language'] . '\mail_inscription.html';
@@ -180,7 +180,7 @@  discard block
 block discarded – undo
180 180
     if ($mode == _EXTCAL_HEADER_HTML) {
181 181
         $template = 'extcal_mail_member_html.tpl';
182 182
     }
183
-    $mail_body = $tpl->fetch('db:' . $template);
183
+    $mail_body = $tpl->fetch('db:'.$template);
184 184
 
185 185
     extcal_SendMail($destinataires, $mail_fromName, $mail_fromemail, $mail_subject, $mail_body, $bEcho = false, $mode = 0, $sep = '|');
186 186
 
@@ -313,7 +313,7 @@  discard block
 block discarded – undo
313 313
     $header   = array();
314 314
     $header[] = "From: {$emailSender}";
315 315
     $header[] = "Reply-To: {$emailSender}";
316
-    $header[] = 'X-Mailer: PHP/' . PHP_VERSION;
316
+    $header[] = 'X-Mailer: PHP/'.PHP_VERSION;
317 317
 
318 318
     if ($mode == _EXTCAL_HEADER_HTML) {
319 319
         $header[] = 'MIME-Version: 1.0';
Please login to merge, or discard this patch.
class/form/formdatetime.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -16,11 +16,11 @@  discard block
 block discarded – undo
16 16
      */
17 17
     public function __construct($form, $startTS = 0, $endTS = 0)
18 18
     {
19
-        $startTS       = (int)$startTS;
19
+        $startTS       = (int) $startTS;
20 20
         $startTS       = ($startTS > 0) ? $startTS : time();
21 21
         $startDatetime = getdate($startTS);
22 22
 
23
-        $endTS       = (int)$endTS;
23
+        $endTS       = (int) $endTS;
24 24
         $endTS       = ($endTS > 0) ? $endTS : time();
25 25
         $endDatetime = getdate($endTS);
26 26
 
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
         for ($i = 0; $i < 24; ++$i) {
29 29
             for ($j = 0; $j < _EXTCAL_TS_MINUTE; $j += 15) {
30 30
                 $key             = ($i * _EXTCAL_TS_HOUR) + ($j * _EXTCAL_TS_MINUTE);
31
-                $timearray[$key] = ($j != 0) ? $i . ':' . $j : $i . ':0' . $j;
31
+                $timearray[$key] = ($j != 0) ? $i.':'.$j : $i.':0'.$j;
32 32
             }
33 33
         }
34 34
         ksort($timearray);
Please login to merge, or discard this patch.
class/utility.php 3 patches
Doc Comments   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -463,8 +463,8 @@
 block discarded – undo
463 463
     /**************************************************************************/
464 464
     /**
465 465
      * @param $color
466
-     * @param $plancher
467
-     * @param $plafond
466
+     * @param integer $plancher
467
+     * @param integer $plafond
468 468
      *
469 469
      * @return string
470 470
      */
Please login to merge, or discard this patch.
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -151,11 +151,11 @@
 block discarded – undo
151 151
             $cat_color = $catList->getVar('cat_color');
152 152
             $checked   = in_array($cat_id, $cat) ? 'checked' : '';
153 153
             $cat       = ''
154
-                         . "<div style='float:left; margin-left:5px;'>"
155
-                         . "<input type='checkbox' name='{$name}[{$cat_id}]' value='1' {$checked}>"
156
-                         . "<div style='absolute:left;height:12px; width:6px; background-color:#{$cat_color}; border:1px solid black; float:left; margin-right:5px;' ></div>"
157
-                         . " {$name}"
158
-                         . '</div>';
154
+                            . "<div style='float:left; margin-left:5px;'>"
155
+                            . "<input type='checkbox' name='{$name}[{$cat_id}]' value='1' {$checked}>"
156
+                            . "<div style='absolute:left;height:12px; width:6px; background-color:#{$cat_color}; border:1px solid black; float:left; margin-right:5px;' ></div>"
157
+                            . " {$name}"
158
+                            . '</div>';
159 159
 
160 160
             $t[] = $cat;
161 161
         }
Please login to merge, or discard this patch.
Spacing   +28 added lines, -28 removed lines patch added patch discarded remove patch
@@ -15,7 +15,7 @@  discard block
 block discarded – undo
15 15
  * L'utilisation de ce formulaire d'adminitration suppose
16 16
  * que la classe correspondante de la table a été générées avec classGenerator
17 17
  **/
18
-require_once XOOPS_ROOT_PATH . '/class/uploader.php';
18
+require_once XOOPS_ROOT_PATH.'/class/uploader.php';
19 19
 
20 20
 /**
21 21
  * Class ExtcalUtility.
@@ -49,12 +49,12 @@  discard block
 block discarded – undo
49 49
     public static function extcal_loadImg(&$REQUEST, &$event_picture1, &$event_picture2)
50 50
     {
51 51
         ///////////////////////////////////////////////////////////////////////////////
52
-        $uploaddir_event = XOOPS_ROOT_PATH . '/uploads/extcal/';
53
-        $uploadurl_event = XOOPS_URL . '/uploads/extcal/';
52
+        $uploaddir_event = XOOPS_ROOT_PATH.'/uploads/extcal/';
53
+        $uploadurl_event = XOOPS_URL.'/uploads/extcal/';
54 54
         //$picture = '';
55 55
         for ($j = 1; $j < 3; ++$j) {
56
-            $delimg = @$REQUEST['delimg_' . $j . ''];
57
-            $delimg = isset($delimg) ? (int)$delimg : 0;
56
+            $delimg = @$REQUEST['delimg_'.$j.''];
57
+            $delimg = isset($delimg) ? (int) $delimg : 0;
58 58
             if (0 == $delimg && !empty($REQUEST['xoops_upload_file'][$j])) {
59 59
                 $upload = new XoopsMediaUploader($uploaddir_event, array(
60 60
                     'image/gif',
@@ -77,15 +77,15 @@  discard block
 block discarded – undo
77 77
                             $event_picture2 = $upload->getSavedFileName();
78 78
                         }
79 79
                     }
80
-                } elseif (!empty($REQUEST['file' . $j])) {
80
+                } elseif (!empty($REQUEST['file'.$j])) {
81 81
                     if ($j == 1) {
82
-                        $event_picture1 = $REQUEST['file' . $j];
82
+                        $event_picture1 = $REQUEST['file'.$j];
83 83
                     } elseif ($j == 2) {
84
-                        $event_picture2 = $REQUEST['file' . $j];
84
+                        $event_picture2 = $REQUEST['file'.$j];
85 85
                     }
86 86
                 }
87 87
             } else {
88
-                $url_event = XOOPS_ROOT_PATH . '/uploads/extcal/' . $REQUEST['file' . $j];
88
+                $url_event = XOOPS_ROOT_PATH.'/uploads/extcal/'.$REQUEST['file'.$j];
89 89
                 if ($j == 1) {
90 90
                     $event_picture1 = '';
91 91
                 } elseif ($j == 2) {
@@ -181,17 +181,17 @@  discard block
 block discarded – undo
181 181
             $select->addOption('', '');
182 182
         }
183 183
 
184
-        $select->addOption('year ASC', _MD_EXTCAL_YEAR . ' ' . _MD_EXTCAL_ORDER_BY_ASC);
185
-        $select->addOption('year DESC', _MD_EXTCAL_YEAR . ' ' . _MD_EXTCAL_ORDER_BY_DESC);
184
+        $select->addOption('year ASC', _MD_EXTCAL_YEAR.' '._MD_EXTCAL_ORDER_BY_ASC);
185
+        $select->addOption('year DESC', _MD_EXTCAL_YEAR.' '._MD_EXTCAL_ORDER_BY_DESC);
186 186
 
187
-        $select->addOption('month ASC', _MD_EXTCAL_MONTH . ' ' . _MD_EXTCAL_ORDER_BY_ASC);
188
-        $select->addOption('month DESC', _MD_EXTCAL_MONTH . ' ' . _MD_EXTCAL_ORDER_BY_DESC);
187
+        $select->addOption('month ASC', _MD_EXTCAL_MONTH.' '._MD_EXTCAL_ORDER_BY_ASC);
188
+        $select->addOption('month DESC', _MD_EXTCAL_MONTH.' '._MD_EXTCAL_ORDER_BY_DESC);
189 189
 
190
-        $select->addOption('event_title ASC', _MD_EXTCAL_ALPHA . ' ' . _MD_EXTCAL_ORDER_BY_ASC);
191
-        $select->addOption('event_title DESC', _MD_EXTCAL_ALPHA . ' ' . _MD_EXTCAL_ORDER_BY_DESC);
190
+        $select->addOption('event_title ASC', _MD_EXTCAL_ALPHA.' '._MD_EXTCAL_ORDER_BY_ASC);
191
+        $select->addOption('event_title DESC', _MD_EXTCAL_ALPHA.' '._MD_EXTCAL_ORDER_BY_DESC);
192 192
 
193
-        $select->addOption('cat_name ASC', _MD_EXTCAL_CATEGORY . ' ' . _MD_EXTCAL_ORDER_BY_ASC);
194
-        $select->addOption('cat_name DESC', _MD_EXTCAL_CATEGORY . ' ' . _MD_EXTCAL_ORDER_BY_DESC);
193
+        $select->addOption('cat_name ASC', _MD_EXTCAL_CATEGORY.' '._MD_EXTCAL_ORDER_BY_ASC);
194
+        $select->addOption('cat_name DESC', _MD_EXTCAL_CATEGORY.' '._MD_EXTCAL_ORDER_BY_DESC);
195 195
 
196 196
         return $select;
197 197
     }
@@ -305,7 +305,7 @@  discard block
 block discarded – undo
305 305
     public static function echoDateArray($period)
306 306
     {
307 307
         foreach ($period as $dt) {
308
-            echo $dt->format("l Y-m-d H:i:s\n") . '<br>';
308
+            echo $dt->format("l Y-m-d H:i:s\n").'<br>';
309 309
         }
310 310
     }
311 311
 
@@ -321,7 +321,7 @@  discard block
 block discarded – undo
321 321
         }
322 322
 
323 323
         $txt = print_r($t, true);
324
-        echo '<pre>Number of items: ' . count($t) . "<br>{$txt}</pre>";
324
+        echo '<pre>Number of items: '.count($t)."<br>{$txt}</pre>";
325 325
     }
326 326
 
327 327
     /*****************************************************************/
@@ -334,7 +334,7 @@  discard block
 block discarded – undo
334 334
         if ($msg != '') {
335 335
             echo "<hr>{$msg}<hr>";
336 336
         }
337
-        echo $line . '<br>';
337
+        echo $line.'<br>';
338 338
     }
339 339
 
340 340
     /*****************************************************************/
@@ -361,7 +361,7 @@  discard block
 block discarded – undo
361 361
             echo "<hr>{$msg}<hr>";
362 362
         }
363 363
 
364
-        echo 'date --->' . $tsName . ' = ' . $ts . ' - ' . date('d-m-Y H:m:s', $ts) . '<br>';
364
+        echo 'date --->'.$tsName.' = '.$ts.' - '.date('d-m-Y H:m:s', $ts).'<br>';
365 365
     }
366 366
 
367 367
     /*****************************************************************/
@@ -475,7 +475,7 @@  discard block
 block discarded – undo
475 475
      */
476 476
     public static function getLighterColor($color, $plancher, $plafond)
477 477
     {
478
-        require_once __DIR__ . '/colorTools.php';
478
+        require_once __DIR__.'/colorTools.php';
479 479
 
480 480
         //$ct = new ColorTools();
481 481
         //return $ct->eclaircir($color,$plancher,$plafond);
@@ -497,7 +497,7 @@  discard block
 block discarded – undo
497 497
                 if (!mkdir($folder) && !is_dir($folder)) {
498 498
                     throw new \RuntimeException(sprintf('Unable to create the %s directory', $folder));
499 499
                 } else {
500
-                    file_put_contents($folder . '/index.html', '<script>history.go(-1);</script>');
500
+                    file_put_contents($folder.'/index.html', '<script>history.go(-1);</script>');
501 501
                 }
502 502
             }
503 503
         } catch (Exception $e) {
@@ -535,10 +535,10 @@  discard block
 block discarded – undo
535 535
         //    @mkdir($dst);
536 536
         while (false !== ($file = readdir($dir))) {
537 537
             if (($file !== '.') && ($file !== '..')) {
538
-                if (is_dir($src . '/' . $file)) {
539
-                    self::recurseCopy($src . '/' . $file, $dst . '/' . $file);
538
+                if (is_dir($src.'/'.$file)) {
539
+                    self::recurseCopy($src.'/'.$file, $dst.'/'.$file);
540 540
                 } else {
541
-                    copy($src . '/' . $file, $dst . '/' . $file);
541
+                    copy($src.'/'.$file, $dst.'/'.$file);
542 542
                 }
543 543
             }
544 544
         }
@@ -565,7 +565,7 @@  discard block
 block discarded – undo
565 565
         $currentVer = substr(XOOPS_VERSION, 6); // get the numeric part of string
566 566
         $currArray  = explode('.', $currentVer);
567 567
         if (null === $requiredVer) {
568
-            $requiredVer = '' . $module->getInfo('min_xoops'); //making sure it's a string
568
+            $requiredVer = ''.$module->getInfo('min_xoops'); //making sure it's a string
569 569
         }
570 570
         $reqArray = explode('.', $requiredVer);
571 571
         $success  = true;
@@ -580,7 +580,7 @@  discard block
 block discarded – undo
580 580
                     break;
581 581
                 }
582 582
             } else {
583
-                if ((int)$v > 0) { // handles versions like x.x.x.0_RC2
583
+                if ((int) $v > 0) { // handles versions like x.x.x.0_RC2
584 584
                     $success = false;
585 585
                     break;
586 586
                 }
Please login to merge, or discard this patch.