Passed
Push — master ( d2520f...3f8ec2 )
by Michael
02:50
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/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.
class/Form/FormRecurRules.php 1 patch
Spacing   +18 added lines, -18 removed lines patch added patch discarded remove patch
@@ -67,45 +67,45 @@  discard block
 block discarded – undo
67 67
         $formObject = new \XoopsFormRadio('', 'rrule_freq', $this->_rrule_freq);
68 68
         $formObject->addOption('none', _MD_EXTCAL_NO_RECCUR_EVENT);
69 69
         $ret .= $formObject->render();
70
-        $ret .= '<br><br><fieldset><legend>' . _MD_EXTCAL_RECCUR_POLICY . '</legend><fieldset><legend>';
70
+        $ret .= '<br><br><fieldset><legend>'._MD_EXTCAL_RECCUR_POLICY.'</legend><fieldset><legend>';
71 71
 
72 72
         $formObject = new \XoopsFormRadio('', 'rrule_freq', $this->_rrule_freq);
73 73
         $formObject->addOption('daily', _MD_EXTCAL_DAILY);
74 74
         $ret .= $formObject->render();
75
-        $ret .= '</legend>' . _MD_EXTCAL_DURING . ' ';
75
+        $ret .= '</legend>'._MD_EXTCAL_DURING.' ';
76 76
 
77 77
         $formObject = new \XoopsFormText('', 'rrule_daily_interval', 3, 2, $this->_rrule_daily_interval);
78 78
         $ret        .= $formObject->render();
79
-        $ret        .= ' ' . _MD_EXTCAL_DAYS . '</fieldset><br><fieldset><legend>';
79
+        $ret        .= ' '._MD_EXTCAL_DAYS.'</fieldset><br><fieldset><legend>';
80 80
 
81 81
         $formObject = new \XoopsFormRadio('', 'rrule_freq', $this->_rrule_freq);
82 82
         $formObject->addOption('weekly', _MD_EXTCAL_WEEKLY);
83 83
         $ret .= $formObject->render();
84
-        $ret .= '</legend>' . _MD_EXTCAL_DURING . ' ';
84
+        $ret .= '</legend>'._MD_EXTCAL_DURING.' ';
85 85
 
86 86
         $formObject = new \XoopsFormText('', 'rrule_weekly_interval', 3, 2, $this->_rrule_weekly_interval);
87 87
         $ret        .= $formObject->render();
88
-        $ret        .= ' ' . _MD_EXTCAL_WEEKS . '<br>';
88
+        $ret        .= ' '._MD_EXTCAL_WEEKS.'<br>';
89 89
 
90 90
         $formObject = new \XoopsFormCheckBox('', 'rrule_weekly_bydays', $this->_rrule_weekly_bydays);
91
-        $formObject->addOption('MO', _MD_EXTCAL_MO2 . '&nbsp;');
92
-        $formObject->addOption('TU', _MD_EXTCAL_TU2 . '&nbsp;');
93
-        $formObject->addOption('WE', _MD_EXTCAL_WE2 . '&nbsp;');
94
-        $formObject->addOption('TH', _MD_EXTCAL_TH2 . '&nbsp;');
95
-        $formObject->addOption('FR', _MD_EXTCAL_FR2 . '&nbsp;');
96
-        $formObject->addOption('SA', _MD_EXTCAL_SA2 . '&nbsp;');
97
-        $formObject->addOption('SU', _MD_EXTCAL_SU2 . '&nbsp;');
91
+        $formObject->addOption('MO', _MD_EXTCAL_MO2.'&nbsp;');
92
+        $formObject->addOption('TU', _MD_EXTCAL_TU2.'&nbsp;');
93
+        $formObject->addOption('WE', _MD_EXTCAL_WE2.'&nbsp;');
94
+        $formObject->addOption('TH', _MD_EXTCAL_TH2.'&nbsp;');
95
+        $formObject->addOption('FR', _MD_EXTCAL_FR2.'&nbsp;');
96
+        $formObject->addOption('SA', _MD_EXTCAL_SA2.'&nbsp;');
97
+        $formObject->addOption('SU', _MD_EXTCAL_SU2.'&nbsp;');
98 98
         $ret .= $formObject->render();
99 99
         $ret .= '</fieldset><br><fieldset><legend>';
100 100
 
101 101
         $formObject = new \XoopsFormRadio('', 'rrule_freq', $this->_rrule_freq);
102 102
         $formObject->addOption('monthly', _MD_EXTCAL_MONTHLY);
103 103
         $ret .= $formObject->render();
104
-        $ret .= '</legend>' . _MD_EXTCAL_DURING . ' ';
104
+        $ret .= '</legend>'._MD_EXTCAL_DURING.' ';
105 105
 
106 106
         $formObject = new \XoopsFormText('', 'rrule_monthly_interval', 3, 2, $this->_rrule_monthly_interval);
107 107
         $ret        .= $formObject->render();
108
-        $ret        .= ' ' . _MD_EXTCAL_MONTH . ', ' . _MD_EXTCAL_ON . ' ';
108
+        $ret        .= ' '._MD_EXTCAL_MONTH.', '._MD_EXTCAL_ON.' ';
109 109
 
110 110
         $formObject = new \XoopsFormSelect('', 'rrule_monthly_byday', $this->_rrule_monthly_byday);
111 111
         $formObject->addOption('', '&nbsp;');
@@ -145,20 +145,20 @@  discard block
 block discarded – undo
145 145
         $formObject->addOption('-1SA', _MD_EXTCAL_LAST_SA);
146 146
         $formObject->addOption('-1SU', _MD_EXTCAL_LAST_SU);
147 147
         $ret .= $formObject->render();
148
-        $ret .= ' ' . _MD_EXTCAL_OR_THE . ' ';
148
+        $ret .= ' '._MD_EXTCAL_OR_THE.' ';
149 149
 
150 150
         $formObject = new \XoopsFormText('', 'rrule_bymonthday', 3, 2, $this->_rrule_bymonthday);
151 151
         $ret        .= $formObject->render();
152
-        $ret        .= ' ' . _MD_EXTCAL_DAY_NUM_MONTH . '</fieldset><br><fieldset><legend>';
152
+        $ret        .= ' '._MD_EXTCAL_DAY_NUM_MONTH.'</fieldset><br><fieldset><legend>';
153 153
 
154 154
         $formObject = new \XoopsFormRadio('', 'rrule_freq', $this->_rrule_freq);
155 155
         $formObject->addOption('yearly', _MD_EXTCAL_YEARLY);
156 156
         $ret .= $formObject->render();
157
-        $ret .= '</legend>' . _MD_EXTCAL_DURING . ' ';
157
+        $ret .= '</legend>'._MD_EXTCAL_DURING.' ';
158 158
 
159 159
         $formObject = new \XoopsFormText('', 'rrule_yearly_interval', 3, 2, $this->_rrule_yearly_interval);
160 160
         $ret        .= $formObject->render();
161
-        $ret        .= ' ' . _MD_EXTCAL_YEARS . '<br>';
161
+        $ret        .= ' '._MD_EXTCAL_YEARS.'<br>';
162 162
 
163 163
         $formObject = new Extcal\Form\FormRRuleCheckBox('', 'rrule_yearly_bymonths', $this->_rrule_yearly_bymonths);
164 164
         $formObject->addOption('1', _MD_EXTCAL_JAN);
Please login to merge, or discard this patch.