Completed
Push — master ( 55a138...ee7aee )
by Michael
05:41
created
include/notification.inc.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -21,7 +21,7 @@
 block discarded – undo
21 21
         $eventHandler = Extcal\Helper::getInstance()->getHandler(_EXTCAL_CLN_EVENT);
22 22
         $event        = $eventHandler->getEvent($itemId, 0, true);
23 23
         $item['name'] = $event->getVar('event_title');
24
-        $item['url']  = XOOPS_URL . '/modules/extcal/event.php?event=' . $event->getVar('event_id');
24
+        $item['url']  = XOOPS_URL.'/modules/extcal/event.php?event='.$event->getVar('event_id');
25 25
 
26 26
         return $item;
27 27
     }
Please login to merge, or discard this patch.
include/oninstall.php 1 patch
Spacing   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -28,7 +28,7 @@  discard block
 block discarded – undo
28 28
 function xoops_module_pre_install_extcal(\XoopsModule $module)
29 29
 {
30 30
     $moduleDirName = basename(dirname(__DIR__));
31
-    $className     = ucfirst($moduleDirName) . 'Utility';
31
+    $className     = ucfirst($moduleDirName).'Utility';
32 32
     if (!class_exists($className)) {
33 33
         xoops_load('utility', $moduleDirName);
34 34
     }
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
 
45 45
     $mod_tables = $module->getInfo('tables');
46 46
     foreach ($mod_tables as $table) {
47
-        $GLOBALS['xoopsDB']->queryF('DROP TABLE IF EXISTS ' . $GLOBALS['xoopsDB']->prefix($table) . ';');
47
+        $GLOBALS['xoopsDB']->queryF('DROP TABLE IF EXISTS '.$GLOBALS['xoopsDB']->prefix($table).';');
48 48
     }
49 49
 
50 50
     return true;
@@ -73,21 +73,21 @@  discard block
 block discarded – undo
73 73
      */
74 74
 
75 75
     // Access right
76
-    $groupPermissionHandler->addRight($moduleDirName . '_perm_mask', 1, XOOPS_GROUP_ADMIN, $moduleId);
77
-    $groupPermissionHandler->addRight($moduleDirName . '_perm_mask', 1, XOOPS_GROUP_USERS, $moduleId);
78
-    $groupPermissionHandler->addRight($moduleDirName . '_perm_mask', 1, XOOPS_GROUP_ANONYMOUS, $moduleId);
76
+    $groupPermissionHandler->addRight($moduleDirName.'_perm_mask', 1, XOOPS_GROUP_ADMIN, $moduleId);
77
+    $groupPermissionHandler->addRight($moduleDirName.'_perm_mask', 1, XOOPS_GROUP_USERS, $moduleId);
78
+    $groupPermissionHandler->addRight($moduleDirName.'_perm_mask', 1, XOOPS_GROUP_ANONYMOUS, $moduleId);
79 79
 
80 80
     // Can submit
81
-    $groupPermissionHandler->addRight($moduleDirName . '_perm_mask', 2, XOOPS_GROUP_ADMIN, $moduleId);
81
+    $groupPermissionHandler->addRight($moduleDirName.'_perm_mask', 2, XOOPS_GROUP_ADMIN, $moduleId);
82 82
 
83 83
     // Auto approve
84
-    $groupPermissionHandler->addRight($moduleDirName . '_perm_mask', 4, XOOPS_GROUP_ADMIN, $moduleId);
84
+    $groupPermissionHandler->addRight($moduleDirName.'_perm_mask', 4, XOOPS_GROUP_ADMIN, $moduleId);
85 85
 
86 86
     //    $moduleDirName = $xoopsModule->getVar('dirname');
87
-    $configurator = include $GLOBALS['xoops']->path('modules/' . $moduleDirName . '/include/config.php');
87
+    $configurator = include $GLOBALS['xoops']->path('modules/'.$moduleDirName.'/include/config.php');
88 88
 
89 89
     /** @var Extcal\Utility $utilityClass */
90
-    $utilityClass = ucfirst($moduleDirName) . 'Utility';
90
+    $utilityClass = ucfirst($moduleDirName).'Utility';
91 91
     if (!class_exists($utilityClass)) {
92 92
         xoops_load('utility', $moduleDirName);
93 93
     }
@@ -99,9 +99,9 @@  discard block
 block discarded – undo
99 99
         }
100 100
     }
101 101
     if (count($configurator['copyFiles']) > 0) {
102
-        $file = __DIR__ . '/../assets/images/blank.png';
102
+        $file = __DIR__.'/../assets/images/blank.png';
103 103
         foreach (array_keys($configurator['copyFiles']) as $i) {
104
-            $dest = $configurator['copyFiles'][$i] . '/blank.png';
104
+            $dest = $configurator['copyFiles'][$i].'/blank.png';
105 105
             $utilityClass::copyFile($file, $dest);
106 106
         }
107 107
     }
Please login to merge, or discard this patch.
preloads/core.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -28,6 +28,6 @@
 block discarded – undo
28 28
      */
29 29
     public static function eventCoreIncludeCommonEnd($args)
30 30
     {
31
-        include __DIR__ . '/autoloader.php';
31
+        include __DIR__.'/autoloader.php';
32 32
     }
33 33
 }
Please login to merge, or discard this patch.
new_event.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -2,9 +2,9 @@  discard block
 block discarded – undo
2 2
 
3 3
 use XoopsModules\Extcal;
4 4
 
5
-include __DIR__ . '/../../mainfile.php';
6
-require_once __DIR__ . '/include/constantes.php';
7
-require_once __DIR__ . '/header.php';
5
+include __DIR__.'/../../mainfile.php';
6
+require_once __DIR__.'/include/constantes.php';
7
+require_once __DIR__.'/header.php';
8 8
 
9 9
 // Getting eXtCal object's handler
10 10
 $eventHandler = Extcal\Helper::getInstance()->getHandler(_EXTCAL_CLN_EVENT);
@@ -12,7 +12,7 @@  discard block
 block discarded – undo
12 12
 $permHandler = Extcal\Perm::getHandler();
13 13
 $xoopsUser   = $xoopsUser ?: null;
14 14
 if (count($permHandler->getAuthorizedCat($xoopsUser, 'extcal_cat_submit')) > 0) {
15
-    include XOOPS_ROOT_PATH . '/header.php';
15
+    include XOOPS_ROOT_PATH.'/header.php';
16 16
 
17 17
     // Title of the page
18 18
     $xoopsTpl->assign('xoops_pagetitle', _MI_EXTCAL_SUBMIT_EVENT);
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
 
23 23
     //$form->display();
24 24
 
25
-    include XOOPS_ROOT_PATH . '/footer.php';
25
+    include XOOPS_ROOT_PATH.'/footer.php';
26 26
 } else {
27 27
     redirect_header('index.php', 3);
28 28
 }
Please login to merge, or discard this patch.
event.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -19,20 +19,20 @@  discard block
 block discarded – undo
19 19
 
20 20
 use XoopsModules\Extcal;
21 21
 
22
-include __DIR__ . '/../../mainfile.php';
23
-require_once __DIR__ . '/include/constantes.php';
22
+include __DIR__.'/../../mainfile.php';
23
+require_once __DIR__.'/include/constantes.php';
24 24
 $params                                  = ['view' => _EXTCAL_NAV_NEW_EVENT, 'file' => _EXTCAL_FILE_NEW_EVENT];
25 25
 $GLOBALS['xoopsOption']['template_main'] = 'extcal_event.tpl';
26
-require_once __DIR__ . '/header.php';
26
+require_once __DIR__.'/header.php';
27 27
 
28 28
 //exit;
29 29
 
30
-include XOOPS_ROOT_PATH . '/include/comment_view.php';
30
+include XOOPS_ROOT_PATH.'/include/comment_view.php';
31 31
 
32 32
 if (!isset($_GET['event'])) {
33 33
     $eventId = 0;
34 34
 } else {
35
-    $eventId = (int)$_GET['event'];
35
+    $eventId = (int) $_GET['event'];
36 36
 }
37 37
 $eventHandler          = Extcal\Helper::getInstance()->getHandler(_EXTCAL_CLN_EVENT);
38 38
 $fileHandler           = Extcal\Helper::getInstance()->getHandler(_EXTCAL_CLN_FILE);
@@ -230,4 +230,4 @@  discard block
 block discarded – undo
230 230
 
231 231
 //function XoopsFormDhtmlTextArea($caption, $name, $value = "", $rows = 5, $cols = 50, $hiddentext = "xoopsHiddenText", $options = array());
232 232
 
233
-include XOOPS_ROOT_PATH . '/footer.php';
233
+include XOOPS_ROOT_PATH.'/footer.php';
Please login to merge, or discard this patch.
edit_event.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -19,10 +19,10 @@  discard block
 block discarded – undo
19 19
 
20 20
 use XoopsModules\Extcal;
21 21
 
22
-include __DIR__ . '/../../mainfile.php';
22
+include __DIR__.'/../../mainfile.php';
23 23
 
24
-include XOOPS_ROOT_PATH . '/class/xoopsformloader.php';
25
-require_once __DIR__ . '/include/constantes.php';
24
+include XOOPS_ROOT_PATH.'/class/xoopsformloader.php';
25
+require_once __DIR__.'/include/constantes.php';
26 26
 
27 27
 $permHandler = Extcal\Perm::getHandler();
28 28
 $xoopsUser   = $xoopsUser ?: null;
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 
35 35
 $params                                  = ['view' => _EXTCAL_NAV_NEW_EVENT, 'file' => _EXTCAL_FILE_NEW_EVENT];
36 36
 $GLOBALS['xoopsOption']['template_main'] = "extcal_view_{$params['view']}.tpl";
37
-include XOOPS_ROOT_PATH . '/header.php';
37
+include XOOPS_ROOT_PATH.'/header.php';
38 38
 /* ========================================================================== */
39 39
 
40 40
 // Tooltips include
@@ -45,7 +45,7 @@  discard block
 block discarded – undo
45 45
 if (!isset($_GET['event'])) {
46 46
     $eventId = 0;
47 47
 } else {
48
-    $eventId = (int)$_GET['event'];
48
+    $eventId = (int) $_GET['event'];
49 49
 }
50 50
 if (!isset($_GET['action'])) {
51 51
     $action = 'edit';
@@ -56,7 +56,7 @@  discard block
 block discarded – undo
56 56
 // Getting eXtCal object's handler
57 57
 $eventHandler = Extcal\Helper::getInstance()->getHandler(_EXTCAL_CLN_EVENT);
58 58
 
59
-include XOOPS_ROOT_PATH . '/header.php';
59
+include XOOPS_ROOT_PATH.'/header.php';
60 60
 
61 61
 // Title of the page
62 62
 $xoopsTpl->assign('xoops_pagetitle', _MI_EXTCAL_SUBMIT_EVENT);
@@ -65,4 +65,4 @@  discard block
 block discarded – undo
65 65
 $form = $eventHandler->getEventForm('user', $action, ['event_id' => $eventId]);
66 66
 $form->display();
67 67
 
68
-include XOOPS_ROOT_PATH . '/footer.php';
68
+include XOOPS_ROOT_PATH.'/footer.php';
Please login to merge, or discard this patch.
class/ColorTools.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -170,9 +170,9 @@
 block discarded – undo
170 170
         $tHex = ['', '', '', ''];
171 171
 
172 172
         $tHex[0] = $aColors[0];
173
-        $tHex[1] = substr('00' . dechex($aColors[1]), -2);
174
-        $tHex[2] = substr('00' . dechex($aColors[2]), -2);
175
-        $tHex[3] = substr('00' . dechex($aColors[3]), -2);
173
+        $tHex[1] = substr('00'.dechex($aColors[1]), -2);
174
+        $tHex[2] = substr('00'.dechex($aColors[2]), -2);
175
+        $tHex[3] = substr('00'.dechex($aColors[3]), -2);
176 176
 
177 177
         $colorHexa = implode('', $tHex);
178 178
 
Please login to merge, or discard this patch.
class/Time.php 1 patch
Spacing   +23 added lines, -23 removed lines patch added patch discarded remove patch
@@ -4,7 +4,7 @@  discard block
 block discarded – undo
4 4
 
5 5
 // defined('XOOPS_ROOT_PATH') || exit('Restricted access.');
6 6
 
7
-require_once XOOPS_ROOT_PATH . '/language/' . $GLOBALS['xoopsConfig']['language'] . '/calendar.php';
7
+require_once XOOPS_ROOT_PATH.'/language/'.$GLOBALS['xoopsConfig']['language'].'/calendar.php';
8 8
 
9 9
 $moduleDirName = basename(dirname(__DIR__));
10 10
 Extcal\Helper::getInstance()->loadLanguage('main');
@@ -92,7 +92,7 @@  discard block
 block discarded – undo
92 92
      */
93 93
     public function getFormatedDate($format, $timestamp)
94 94
     {
95
-        $patterns     = [
95
+        $patterns = [
96 96
             '/January/',
97 97
             '/February/',
98 98
             '/March/',
@@ -145,18 +145,18 @@  discard block
 block discarded – undo
145 145
             _CAL_OCTOBER,
146 146
             _CAL_NOVEMBER,
147 147
             _CAL_DECEMBER,
148
-            substr(_CAL_JANUARY, 0, 3) . ' ',
149
-            substr(_CAL_FEBRUARY, 0, 3) . ' ',
150
-            substr(_CAL_MARCH, 0, 3) . ' ',
151
-            substr(_CAL_APRIL, 0, 3) . ' ',
152
-            substr(_CAL_MAY, 0, 3) . ' ',
153
-            substr(_CAL_JUNE, 0, 3) . ' ',
154
-            substr(_CAL_JULY, 0, 3) . ' ',
155
-            substr(_CAL_AUGUST, 0, 3) . ' ',
156
-            substr(_CAL_SEPTEMBER, 0, 3) . ' ',
157
-            substr(_CAL_OCTOBER, 0, 3) . ' ',
158
-            substr(_CAL_NOVEMBER, 0, 3) . ' ',
159
-            substr(_CAL_DECEMBER, 0, 3) . ' ',
148
+            substr(_CAL_JANUARY, 0, 3).' ',
149
+            substr(_CAL_FEBRUARY, 0, 3).' ',
150
+            substr(_CAL_MARCH, 0, 3).' ',
151
+            substr(_CAL_APRIL, 0, 3).' ',
152
+            substr(_CAL_MAY, 0, 3).' ',
153
+            substr(_CAL_JUNE, 0, 3).' ',
154
+            substr(_CAL_JULY, 0, 3).' ',
155
+            substr(_CAL_AUGUST, 0, 3).' ',
156
+            substr(_CAL_SEPTEMBER, 0, 3).' ',
157
+            substr(_CAL_OCTOBER, 0, 3).' ',
158
+            substr(_CAL_NOVEMBER, 0, 3).' ',
159
+            substr(_CAL_DECEMBER, 0, 3).' ',
160 160
             _CAL_SUNDAY,
161 161
             _CAL_MONDAY,
162 162
             _CAL_TUESDAY,
@@ -164,13 +164,13 @@  discard block
 block discarded – undo
164 164
             _CAL_THURSDAY,
165 165
             _CAL_FRIDAY,
166 166
             _CAL_SATURDAY,
167
-            substr(_CAL_SUNDAY, 0, 3) . ' ',
168
-            substr(_CAL_MONDAY, 0, 3) . ' ',
169
-            substr(_CAL_TUESDAY, 0, 3) . ' ',
170
-            substr(_CAL_WEDNESDAY, 0, 3) . ' ',
171
-            substr(_CAL_THURSDAY, 0, 3) . ' ',
172
-            substr(_CAL_FRIDAY, 0, 3) . ' ',
173
-            substr(_CAL_SATURDAY, 0, 3) . ' ',
167
+            substr(_CAL_SUNDAY, 0, 3).' ',
168
+            substr(_CAL_MONDAY, 0, 3).' ',
169
+            substr(_CAL_TUESDAY, 0, 3).' ',
170
+            substr(_CAL_WEDNESDAY, 0, 3).' ',
171
+            substr(_CAL_THURSDAY, 0, 3).' ',
172
+            substr(_CAL_FRIDAY, 0, 3).' ',
173
+            substr(_CAL_SATURDAY, 0, 3).' ',
174 174
         ];
175 175
 
176 176
         return preg_replace($patterns, $replacements, date($format, $timestamp));
@@ -212,7 +212,7 @@  discard block
 block discarded – undo
212 212
                 array_shift($eventOptions);
213 213
                 $day = '';
214 214
                 foreach ($eventOptions as $option) {
215
-                    $day .= ' ' . $daysName[$option] . ', ';
215
+                    $day .= ' '.$daysName[$option].', ';
216 216
                 }
217 217
                 $ret = sprintf(_MD_EXTCAL_RR_WEEKLY, $day, $interval);
218 218
 
@@ -331,7 +331,7 @@  discard block
 block discarded – undo
331 331
                 array_shift($eventOptions);
332 332
                 $month = '';
333 333
                 foreach ($eventOptions as $option) {
334
-                    $month .= ' ' . $monthName[$option] . ', ';
334
+                    $month .= ' '.$monthName[$option].', ';
335 335
                 }
336 336
                 $dayString = $day;
337 337
                 if (array_key_exists($day, $monthDays)) {
Please login to merge, or discard this patch.
class/TableForm.php 1 patch
Spacing   +12 added lines, -12 removed lines patch added patch discarded remove patch
@@ -55,13 +55,13 @@  discard block
 block discarded – undo
55 55
      */
56 56
     public function insertBreak($extra = '', $class = '')
57 57
     {
58
-        $class = ('' != $class) ? " class='" . preg_replace('/[^A-Za-z0-9\s\s_-]/i', '', $class) . "'" : '';
58
+        $class = ('' != $class) ? " class='".preg_replace('/[^A-Za-z0-9\s\s_-]/i', '', $class)."'" : '';
59 59
         // Fix for $extra tag not showing
60 60
         if ($extra) {
61
-            $extra = '<tr><td colspan="2" ' . $class . '>' . $extra . '</td></tr>';
61
+            $extra = '<tr><td colspan="2" '.$class.'>'.$extra.'</td></tr>';
62 62
             $this->addElement($extra);
63 63
         } else {
64
-            $extra = '<tr><td colspan="2" ' . $class . '>&nbsp;</td></tr>';
64
+            $extra = '<tr><td colspan="2" '.$class.'>&nbsp;</td></tr>';
65 65
             $this->addElement($extra);
66 66
         }
67 67
     }
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
         }
91 91
 
92 92
         if ('' != $title) {
93
-            $ret .= '<tr><th colspan="2">' . $title . '</th></tr>';
93
+            $ret .= '<tr><th colspan="2">'.$title.'</th></tr>';
94 94
         }
95 95
 
96 96
         $hidden = '';
@@ -102,24 +102,24 @@  discard block
 block discarded – undo
102 102
                 if (!$ele->getNocolspan()) {
103 103
                     $ret .= '<tr valign="top" align="left"><td class="head">';
104 104
                     if ('' != ($caption = $ele->getCaption())) {
105
-                        $ret .= '<div class="xoops-form-element-caption' . ($ele->isRequired() ? '-required' : '') . '">';
106
-                        $ret .= '<span class="caption-text">' . $caption . '</span>';
105
+                        $ret .= '<div class="xoops-form-element-caption'.($ele->isRequired() ? '-required' : '').'">';
106
+                        $ret .= '<span class="caption-text">'.$caption.'</span>';
107 107
                         $ret .= '<span class="caption-marker">*</span>';
108 108
                         $ret .= '</div>';
109 109
                     }
110 110
                     if ('' != ($desc = $ele->getDescription())) {
111
-                        $ret .= '<div class="xoops-form-element-help">' . $desc . '</div>';
111
+                        $ret .= '<div class="xoops-form-element-help">'.$desc.'</div>';
112 112
                     }
113
-                    $ret .= '</td><td class="' . $class . '">' . $ele->render() . '</td></tr>' . NWLINE;
113
+                    $ret .= '</td><td class="'.$class.'">'.$ele->render().'</td></tr>'.NWLINE;
114 114
                 } else {
115 115
                     $ret .= '<tr valign="top" align="left"><td class="head" colspan="2">';
116 116
                     if ('' != ($caption = $ele->getCaption())) {
117
-                        $ret .= '<div class="xoops-form-element-caption' . ($ele->isRequired() ? '-required' : '') . '">';
118
-                        $ret .= '<span class="caption-text">' . $caption . '</span>';
117
+                        $ret .= '<div class="xoops-form-element-caption'.($ele->isRequired() ? '-required' : '').'">';
118
+                        $ret .= '<span class="caption-text">'.$caption.'</span>';
119 119
                         $ret .= '<span class="caption-marker">*</span>';
120 120
                         $ret .= '</div>';
121 121
                     }
122
-                    $ret .= '</td></tr><tr valign="top" align="left"><td class="' . $class . '" colspan="2">' . $ele->render() . '</td></tr>';
122
+                    $ret .= '</td></tr><tr valign="top" align="left"><td class="'.$class.'" colspan="2">'.$ele->render().'</td></tr>';
123 123
                 }
124 124
             } else {
125 125
                 $hidden .= $ele->render();
@@ -130,7 +130,7 @@  discard block
 block discarded – undo
130 130
             $ret .= '</table>';
131 131
         }
132 132
 
133
-        $ret .= NWLINE . ' ' . $hidden . NWLINE;
133
+        $ret .= NWLINE.' '.$hidden.NWLINE;
134 134
 
135 135
         return $ret;
136 136
     }
Please login to merge, or discard this patch.