@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | if ((!defined('XOOPS_ROOT_PATH')) || !($GLOBALS['xoopsUser'] instanceof XoopsUser) |
25 | 25 | || !$GLOBALS['xoopsUser']->IsAdmin() |
26 | 26 | ) { |
27 | - exit('Restricted access' . PHP_EOL); |
|
27 | + exit('Restricted access'.PHP_EOL); |
|
28 | 28 | } |
29 | 29 | |
30 | 30 | /** |
@@ -50,7 +50,7 @@ discard block |
||
50 | 50 | { |
51 | 51 | $moduleDirName = basename(dirname(__DIR__)); |
52 | 52 | /** @var \ContactUtility $classUtility */ |
53 | - $classUtility = ucfirst($moduleDirName) . 'Utility'; |
|
53 | + $classUtility = ucfirst($moduleDirName).'Utility'; |
|
54 | 54 | if (!class_exists($classUtility)) { |
55 | 55 | xoops_load('utility', $moduleDirName); |
56 | 56 | } |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | $xoopsDB = XoopsDatabaseFactory::getDatabaseConnection(); |
84 | 84 | |
85 | 85 | if ($previousVersion < 180) { |
86 | - $sql = 'CREATE TABLE ' . $xoopsDB->prefix('contact') . ' ( |
|
86 | + $sql = 'CREATE TABLE '.$xoopsDB->prefix('contact').' ( |
|
87 | 87 | contact_id int(10) unsigned NOT NULL auto_increment, |
88 | 88 | contact_uid int(10) NOT NULL, |
89 | 89 | contact_cid int(10) NOT NULL, |
@@ -108,38 +108,38 @@ discard block |
||
108 | 108 | |
109 | 109 | if ($previousVersion < 181) { |
110 | 110 | // Add contact_platform |
111 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . "` ADD `contact_platform` ENUM('Android','Ios','Web') NOT NULL DEFAULT 'Web'"; |
|
111 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact')."` ADD `contact_platform` ENUM('Android','Ios','Web') NOT NULL DEFAULT 'Web'"; |
|
112 | 112 | $xoopsDB->query($sql); |
113 | 113 | // Add contact_type |
114 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . "` ADD `contact_type` ENUM('Contact','Phone','Mail') NOT NULL DEFAULT 'Contact'"; |
|
114 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact')."` ADD `contact_type` ENUM('Contact','Phone','Mail') NOT NULL DEFAULT 'Contact'"; |
|
115 | 115 | $xoopsDB->query($sql); |
116 | 116 | // Add index contact_uid |
117 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . '` ADD INDEX `contact_uid` ( `contact_uid` )'; |
|
117 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact').'` ADD INDEX `contact_uid` ( `contact_uid` )'; |
|
118 | 118 | $xoopsDB->query($sql); |
119 | 119 | // Add index contact_cid |
120 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . '` ADD INDEX `contact_cid` ( `contact_cid` )'; |
|
120 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact').'` ADD INDEX `contact_cid` ( `contact_cid` )'; |
|
121 | 121 | $xoopsDB->query($sql); |
122 | 122 | // Add index contact_create |
123 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . '` ADD INDEX `contact_create` ( `contact_create` )'; |
|
123 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact').'` ADD INDEX `contact_create` ( `contact_create` )'; |
|
124 | 124 | $xoopsDB->query($sql); |
125 | 125 | // Add index contact_mail |
126 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . '` ADD INDEX `contact_mail` ( `contact_mail` )'; |
|
126 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact').'` ADD INDEX `contact_mail` ( `contact_mail` )'; |
|
127 | 127 | $xoopsDB->query($sql); |
128 | 128 | // Add index contact_phone |
129 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . '` ADD INDEX `contact_phone` ( `contact_phone` )'; |
|
129 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact').'` ADD INDEX `contact_phone` ( `contact_phone` )'; |
|
130 | 130 | $xoopsDB->query($sql); |
131 | 131 | // Add index contact_platform |
132 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . '` ADD INDEX `contact_platform` ( `contact_platform` )'; |
|
132 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact').'` ADD INDEX `contact_platform` ( `contact_platform` )'; |
|
133 | 133 | $xoopsDB->query($sql); |
134 | 134 | // Add index contact_type |
135 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('contact') . '` ADD INDEX `contact_type` ( `contact_type` )'; |
|
135 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('contact').'` ADD INDEX `contact_type` ( `contact_type` )'; |
|
136 | 136 | $xoopsDB->query($sql); |
137 | 137 | } |
138 | 138 | |
139 | 139 | if ($previousVersion < 226) { |
140 | - require_once __DIR__ . '/config.php'; |
|
140 | + require_once __DIR__.'/config.php'; |
|
141 | 141 | $configurator = new ContentConfigurator(); |
142 | - $classUtility = ucfirst($moduleDirName) . 'Utility'; |
|
142 | + $classUtility = ucfirst($moduleDirName).'Utility'; |
|
143 | 143 | if (!class_exists($classUtility)) { |
144 | 144 | xoops_load('utility', $moduleDirName); |
145 | 145 | } |
@@ -147,14 +147,14 @@ discard block |
||
147 | 147 | //delete old HTML templates |
148 | 148 | if (count($configurator->templateFolders) > 0) { |
149 | 149 | foreach ($configurator->templateFolders as $folder) { |
150 | - $templateFolder = $GLOBALS['xoops']->path('modules/' . $moduleDirName . $folder); |
|
150 | + $templateFolder = $GLOBALS['xoops']->path('modules/'.$moduleDirName.$folder); |
|
151 | 151 | if (is_dir($templateFolder)) { |
152 | 152 | $templateList = array_diff(scandir($templateFolder, SCANDIR_SORT_NONE), array('..', '.')); |
153 | 153 | foreach ($templateList as $k => $v) { |
154 | - $fileInfo = new SplFileInfo($templateFolder . $v); |
|
154 | + $fileInfo = new SplFileInfo($templateFolder.$v); |
|
155 | 155 | if ($fileInfo->getExtension() === 'html' && $fileInfo->getFilename() !== 'index.html') { |
156 | - if (file_exists($templateFolder . $v)) { |
|
157 | - unlink($templateFolder . $v); |
|
156 | + if (file_exists($templateFolder.$v)) { |
|
157 | + unlink($templateFolder.$v); |
|
158 | 158 | } |
159 | 159 | } |
160 | 160 | } |
@@ -166,7 +166,7 @@ discard block |
||
166 | 166 | if (count($configurator->oldFiles) > 0) { |
167 | 167 | // foreach (array_keys($GLOBALS['uploadFolders']) as $i) { |
168 | 168 | foreach (array_keys($configurator->oldFiles) as $i) { |
169 | - $tempFile = $GLOBALS['xoops']->path('modules/' . $moduleDirName . $configurator->oldFiles[$i]); |
|
169 | + $tempFile = $GLOBALS['xoops']->path('modules/'.$moduleDirName.$configurator->oldFiles[$i]); |
|
170 | 170 | if (is_file($tempFile)) { |
171 | 171 | unlink($tempFile); |
172 | 172 | } |
@@ -178,7 +178,7 @@ discard block |
||
178 | 178 | if (count($configurator->oldFolders) > 0) { |
179 | 179 | // foreach (array_keys($GLOBALS['uploadFolders']) as $i) { |
180 | 180 | foreach (array_keys($configurator->oldFolders) as $i) { |
181 | - $tempFolder = $GLOBALS['xoops']->path('modules/' . $moduleDirName . $configurator->oldFolders[$i]); |
|
181 | + $tempFolder = $GLOBALS['xoops']->path('modules/'.$moduleDirName.$configurator->oldFolders[$i]); |
|
182 | 182 | /* @var $folderHandler XoopsObjectHandler */ |
183 | 183 | $folderHandler = XoopsFile::getHandler('folder', $tempFolder); |
184 | 184 | $folderHandler->delete($tempFolder); |
@@ -195,15 +195,15 @@ discard block |
||
195 | 195 | |
196 | 196 | // --- COPY blank.png FILES --------------- |
197 | 197 | if (count($configurator->blankFiles) > 0) { |
198 | - $file = __DIR__ . '/../assets/images/blank.png'; |
|
198 | + $file = __DIR__.'/../assets/images/blank.png'; |
|
199 | 199 | foreach (array_keys($configurator->blankFiles) as $i) { |
200 | - $dest = $configurator->blankFiles[$i] . '/blank.png'; |
|
200 | + $dest = $configurator->blankFiles[$i].'/blank.png'; |
|
201 | 201 | $classUtility::copyFile($file, $dest); |
202 | 202 | } |
203 | 203 | } |
204 | 204 | |
205 | 205 | //delete .html entries from the tpl table |
206 | - $sql = 'DELETE FROM ' . $GLOBALS['xoopsDB']->prefix('tplfile') . " WHERE `tpl_module` = '" . $module->getVar('dirname', 'n') . '\' AND `tpl_file` LIKE \'%.html%\''; |
|
206 | + $sql = 'DELETE FROM '.$GLOBALS['xoopsDB']->prefix('tplfile')." WHERE `tpl_module` = '".$module->getVar('dirname', 'n').'\' AND `tpl_file` LIKE \'%.html%\''; |
|
207 | 207 | $GLOBALS['xoopsDB']->queryF($sql); |
208 | 208 | |
209 | 209 | /** @var XoopsGroupPermHandler $gpermHandler */ |
@@ -20,10 +20,10 @@ |
||
20 | 20 | $pathIcon32 = Xmf\Module\Admin::iconUrl('', 32); |
21 | 21 | |
22 | 22 | echo "<div class='adminfooter'>\n" |
23 | - ." <div style='text-align: center;'>\n" |
|
24 | - ." <a href='http://www.xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" |
|
25 | - ." </div>\n" |
|
26 | - .' ' . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" |
|
27 | - .'</div>'; |
|
23 | + ." <div style='text-align: center;'>\n" |
|
24 | + ." <a href='http://www.xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" |
|
25 | + ." </div>\n" |
|
26 | + .' ' . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" |
|
27 | + .'</div>'; |
|
28 | 28 | |
29 | 29 | xoops_cp_footer(); |
@@ -17,13 +17,13 @@ |
||
17 | 17 | * @author XOOPS Development Team |
18 | 18 | */ |
19 | 19 | |
20 | -$pathIcon32 = Xmf\Module\Admin::iconUrl('', 32); |
|
20 | +$pathIcon32 = Xmf\Module\Admin::iconUrl('', 32); |
|
21 | 21 | |
22 | 22 | echo "<div class='adminfooter'>\n" |
23 | 23 | ." <div style='text-align: center;'>\n" |
24 | 24 | ." <a href='http://www.xoops.org' rel='external'><img src='{$pathIcon32}/xoopsmicrobutton.gif' alt='XOOPS' title='XOOPS'></a>\n" |
25 | 25 | ." </div>\n" |
26 | - .' ' . _AM_MODULEADMIN_ADMIN_FOOTER . "\n" |
|
26 | + .' '._AM_MODULEADMIN_ADMIN_FOOTER."\n" |
|
27 | 27 | .'</div>'; |
28 | 28 | |
29 | 29 | xoops_cp_footer(); |