@@ -42,18 +42,18 @@ |
||
| 42 | 42 | $ret = '<table><tr>'; |
| 43 | 43 | $i = 0; |
| 44 | 44 | if (count($this->getOptions()) > 1 && '[]' !== substr($this->getName(), -2, 2)) { |
| 45 | - $newname = $this->getName() . '[]'; |
|
| 45 | + $newname = $this->getName().'[]'; |
|
| 46 | 46 | $this->setName($newname); |
| 47 | 47 | } |
| 48 | 48 | foreach ($this->getOptions() as $value => $name) { |
| 49 | 49 | if (0 == (++$i) % 6) { |
| 50 | 50 | $ret .= '</tr><tr>'; |
| 51 | 51 | } |
| 52 | - $ret .= "<td><input type='checkbox' name='" . $this->getName() . "' value='" . $value . "'"; |
|
| 52 | + $ret .= "<td><input type='checkbox' name='".$this->getName()."' value='".$value."'"; |
|
| 53 | 53 | if (count($this->getValue()) > 0 && in_array($value, $this->getValue())) { |
| 54 | 54 | $ret .= ' checked'; |
| 55 | 55 | } |
| 56 | - $ret .= $this->getExtra() . '>' . $name . "</td>\n"; |
|
| 56 | + $ret .= $this->getExtra().'>'.$name."</td>\n"; |
|
| 57 | 57 | } |
| 58 | 58 | $ret .= '</tr></table>'; |
| 59 | 59 | |
@@ -43,13 +43,13 @@ |
||
| 43 | 43 | { |
| 44 | 44 | $ret = ''; |
| 45 | 45 | if (count($this->getOptions()) > 1 && '[]' !== substr($this->getName(), -2, 2)) { |
| 46 | - $newname = $this->getName() . '[]'; |
|
| 46 | + $newname = $this->getName().'[]'; |
|
| 47 | 47 | $this->setName($newname); |
| 48 | 48 | } |
| 49 | 49 | foreach ($this->getOptions() as $value => $name) { |
| 50 | - $ret .= "<input type='checkbox' name='" . $this->getName() . "' value='" . $value . "'"; |
|
| 50 | + $ret .= "<input type='checkbox' name='".$this->getName()."' value='".$value."'"; |
|
| 51 | 51 | $ret .= ' checked'; |
| 52 | - $ret .= $this->getExtra() . '>' . $name . "<br>\n"; |
|
| 52 | + $ret .= $this->getExtra().'>'.$name."<br>\n"; |
|
| 53 | 53 | } |
| 54 | 54 | |
| 55 | 55 | return $ret; |
@@ -201,7 +201,7 @@ discard block |
||
| 201 | 201 | */ |
| 202 | 202 | public function setMin($min) |
| 203 | 203 | { |
| 204 | - $this->_min = (int)$min; |
|
| 204 | + $this->_min = (int) $min; |
|
| 205 | 205 | } |
| 206 | 206 | /*-----------------------------------------------------------------*/ |
| 207 | 207 | /** |
@@ -219,7 +219,7 @@ discard block |
||
| 219 | 219 | */ |
| 220 | 220 | public function setMax($max) |
| 221 | 221 | { |
| 222 | - $this->_max = (int)$max; |
|
| 222 | + $this->_max = (int) $max; |
|
| 223 | 223 | } |
| 224 | 224 | |
| 225 | 225 | /*-----------------------------------------------------------------*/ |
@@ -241,7 +241,7 @@ discard block |
||
| 241 | 241 | */ |
| 242 | 242 | public function setSmallIncrement($smallIncrement) |
| 243 | 243 | { |
| 244 | - $this->_smallIncrement = (int)$smallIncrement; |
|
| 244 | + $this->_smallIncrement = (int) $smallIncrement; |
|
| 245 | 245 | if (0 == $this->_smallIncrement) { |
| 246 | 246 | $this->_smallIncrement = 1; |
| 247 | 247 | } |
@@ -263,7 +263,7 @@ discard block |
||
| 263 | 263 | */ |
| 264 | 264 | public function setLargeIncrement($largeIncrement) |
| 265 | 265 | { |
| 266 | - $this->_largeIncrement = (int)$largeIncrement; |
|
| 266 | + $this->_largeIncrement = (int) $largeIncrement; |
|
| 267 | 267 | if (0 == $this->_largeIncrement) { |
| 268 | 268 | $this->_largeIncrement = 10; |
| 269 | 269 | } |
@@ -404,7 +404,7 @@ discard block |
||
| 404 | 404 | $sFolderImg = "{$sSpinFolder}/images/{$this->getImgFolder()}/"; |
| 405 | 405 | |
| 406 | 406 | $prefixe = $this->getName(); |
| 407 | - $prefixe2 = 'spin' . $prefixe; |
|
| 407 | + $prefixe2 = 'spin'.$prefixe; |
|
| 408 | 408 | |
| 409 | 409 | $smallIncrement = $this->getSmallIncrement(); |
| 410 | 410 | $largeIncrement = $this->getLargeIncrement(); |
@@ -423,7 +423,7 @@ discard block |
||
| 423 | 423 | $t = []; |
| 424 | 424 | |
| 425 | 425 | if ($this->_loadJS) { |
| 426 | - $js = $sSpinFolder . '/js/spin.js'; |
|
| 426 | + $js = $sSpinFolder.'/js/spin.js'; |
|
| 427 | 427 | $t[] = "<script src='{$js}' type='text/javascript'></script>"; |
| 428 | 428 | } |
| 429 | 429 | |
@@ -468,7 +468,7 @@ discard block |
||
| 468 | 468 | //------------------------------------------------------- |
| 469 | 469 | |
| 470 | 470 | $t[] = ' </tr>'; |
| 471 | - $t[] = '</table>' . "\n"; |
|
| 471 | + $t[] = '</table>'."\n"; |
|
| 472 | 472 | $t[] = '</div>'; |
| 473 | 473 | //------------------------------------------- |
| 474 | 474 | $html = implode("\n", $t); |
@@ -33,13 +33,13 @@ |
||
| 33 | 33 | global $xoopsDB; |
| 34 | 34 | |
| 35 | 35 | // Create eXtcal upload directory if don't exist |
| 36 | - $dir = XOOPS_ROOT_PATH . '/uploads/extcal'; |
|
| 36 | + $dir = XOOPS_ROOT_PATH.'/uploads/extcal'; |
|
| 37 | 37 | if (!is_dir($dir)) { |
| 38 | 38 | mkdir($dir); |
| 39 | 39 | |
| 40 | 40 | // Copy index.html files on uploads folders |
| 41 | - $indexFile = __DIR__ . '/index.html'; |
|
| 42 | - copy($indexFile, XOOPS_ROOT_PATH . '/uploads/extcal/index.html'); |
|
| 41 | + $indexFile = __DIR__.'/index.html'; |
|
| 42 | + copy($indexFile, XOOPS_ROOT_PATH.'/uploads/extcal/index.html'); |
|
| 43 | 43 | } |
| 44 | 44 | |
| 45 | 45 | // Create who's not going table to fix bug. If the table exist, the query will faile |
@@ -34,19 +34,19 @@ |
||
| 34 | 34 | //$xoopsDB = \XoopsDatabaseFactory::getDatabaseConnection(); |
| 35 | 35 | $xoopsDB = \XoopsDatabaseFactory::getDatabaseConnection(); |
| 36 | 36 | |
| 37 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('extcal_event') . "` CHANGE `event_approved` `event_approved` TINYINT( 1 ) NOT NULL DEFAULT '0' ;"; |
|
| 37 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('extcal_event')."` CHANGE `event_approved` `event_approved` TINYINT( 1 ) NOT NULL DEFAULT '0' ;"; |
|
| 38 | 38 | $xoopsDB->query($sql); |
| 39 | 39 | |
| 40 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('extcal_event') . '` ADD `event_isrecur` TINYINT( 1 ) NOT NULL AFTER `event_nbmember` ;'; |
|
| 40 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('extcal_event').'` ADD `event_isrecur` TINYINT( 1 ) NOT NULL AFTER `event_nbmember` ;'; |
|
| 41 | 41 | $xoopsDB->query($sql); |
| 42 | 42 | |
| 43 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('extcal_event') . '` ADD `event_recur_rules` VARCHAR( 255 ) NOT NULL AFTER `event_isrecur` '; |
|
| 43 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('extcal_event').'` ADD `event_recur_rules` VARCHAR( 255 ) NOT NULL AFTER `event_isrecur` '; |
|
| 44 | 44 | $xoopsDB->query($sql); |
| 45 | 45 | |
| 46 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('extcal_event') . '` ADD `event_recur_start` INT( 11 ) NOT NULL AFTER `event_recur_rules` ;'; |
|
| 46 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('extcal_event').'` ADD `event_recur_start` INT( 11 ) NOT NULL AFTER `event_recur_rules` ;'; |
|
| 47 | 47 | $xoopsDB->query($sql); |
| 48 | 48 | |
| 49 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('extcal_event') . '` ADD `event_recur_end` INT( 11 ) NOT NULL AFTER `event_recur_start` ;'; |
|
| 49 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('extcal_event').'` ADD `event_recur_end` INT( 11 ) NOT NULL AFTER `event_recur_start` ;'; |
|
| 50 | 50 | $xoopsDB->query($sql); |
| 51 | 51 | |
| 52 | 52 | $sql = 'CREATE TABLE `' |
@@ -32,7 +32,7 @@ |
||
| 32 | 32 | { |
| 33 | 33 | global $xoopsDB; |
| 34 | 34 | |
| 35 | - $sql = 'ALTER TABLE `' . $xoopsDB->prefix('extcal_event') . "` ADD `event_nbmember` TINYINT(4) NOT NULL DEFAULT '0' AFTER `event_submitdate` ;"; |
|
| 35 | + $sql = 'ALTER TABLE `'.$xoopsDB->prefix('extcal_event')."` ADD `event_nbmember` TINYINT(4) NOT NULL DEFAULT '0' AFTER `event_submitdate` ;"; |
|
| 36 | 36 | $xoopsDB->query($sql); |
| 37 | 37 | } |
| 38 | 38 | |
@@ -18,7 +18,7 @@ discard block |
||
| 18 | 18 | |
| 19 | 19 | use XoopsModules\Extcal; |
| 20 | 20 | |
| 21 | -require_once XOOPS_ROOT_PATH . '/class/uploader.php'; |
|
| 21 | +require_once XOOPS_ROOT_PATH.'/class/uploader.php'; |
|
| 22 | 22 | |
| 23 | 23 | /** |
| 24 | 24 | * @param $eventId |
@@ -47,12 +47,12 @@ discard block |
||
| 47 | 47 | function extcal_loadImg(&$REQUEST, &$event_picture1, &$event_picture2) |
| 48 | 48 | { |
| 49 | 49 | /////////////////////////////////////////////////////////////////////////////// |
| 50 | - $uploaddir_event = XOOPS_ROOT_PATH . '/uploads/extcal/'; |
|
| 51 | - $uploadurl_event = XOOPS_URL . '/uploads/extcal/'; |
|
| 50 | + $uploaddir_event = XOOPS_ROOT_PATH.'/uploads/extcal/'; |
|
| 51 | + $uploadurl_event = XOOPS_URL.'/uploads/extcal/'; |
|
| 52 | 52 | //$picture = ''; |
| 53 | 53 | for ($j = 1; $j < 3; ++$j) { |
| 54 | - $delimg = @$REQUEST['delimg_' . $j . '']; |
|
| 55 | - $delimg = isset($delimg) ? (int)$delimg : 0; |
|
| 54 | + $delimg = @$REQUEST['delimg_'.$j.'']; |
|
| 55 | + $delimg = isset($delimg) ? (int) $delimg : 0; |
|
| 56 | 56 | if (0 == $delimg && !empty($REQUEST['xoops_upload_file'][$j])) { |
| 57 | 57 | $upload = new \XoopsMediaUploader($uploaddir_event, [ |
| 58 | 58 | 'image/gif', |
@@ -75,15 +75,15 @@ discard block |
||
| 75 | 75 | $event_picture2 = $upload->getSavedFileName(); |
| 76 | 76 | } |
| 77 | 77 | } |
| 78 | - } elseif (!empty($REQUEST['file' . $j])) { |
|
| 78 | + } elseif (!empty($REQUEST['file'.$j])) { |
|
| 79 | 79 | if (1 == $j) { |
| 80 | - $event_picture1 = $REQUEST['file' . $j]; |
|
| 80 | + $event_picture1 = $REQUEST['file'.$j]; |
|
| 81 | 81 | } elseif (2 == $j) { |
| 82 | - $event_picture2 = $REQUEST['file' . $j]; |
|
| 82 | + $event_picture2 = $REQUEST['file'.$j]; |
|
| 83 | 83 | } |
| 84 | 84 | } |
| 85 | 85 | } else { |
| 86 | - $url_event = XOOPS_ROOT_PATH . '/uploads/extcal/' . $REQUEST['file' . $j]; |
|
| 86 | + $url_event = XOOPS_ROOT_PATH.'/uploads/extcal/'.$REQUEST['file'.$j]; |
|
| 87 | 87 | if (1 == $j) { |
| 88 | 88 | $event_picture1 = ''; |
| 89 | 89 | } elseif (2 == $j) { |
@@ -179,17 +179,17 @@ discard block |
||
| 179 | 179 | $select->addOption('', ''); |
| 180 | 180 | } |
| 181 | 181 | |
| 182 | - $select->addOption('year ASC', _MD_EXTCAL_YEAR . ' ' . _MD_EXTCAL_ORDER_BY_ASC); |
|
| 183 | - $select->addOption('year DESC', _MD_EXTCAL_YEAR . ' ' . _MD_EXTCAL_ORDER_BY_DESC); |
|
| 182 | + $select->addOption('year ASC', _MD_EXTCAL_YEAR.' '._MD_EXTCAL_ORDER_BY_ASC); |
|
| 183 | + $select->addOption('year DESC', _MD_EXTCAL_YEAR.' '._MD_EXTCAL_ORDER_BY_DESC); |
|
| 184 | 184 | |
| 185 | - $select->addOption('month ASC', _MD_EXTCAL_MONTH . ' ' . _MD_EXTCAL_ORDER_BY_ASC); |
|
| 186 | - $select->addOption('month DESC', _MD_EXTCAL_MONTH . ' ' . _MD_EXTCAL_ORDER_BY_DESC); |
|
| 185 | + $select->addOption('month ASC', _MD_EXTCAL_MONTH.' '._MD_EXTCAL_ORDER_BY_ASC); |
|
| 186 | + $select->addOption('month DESC', _MD_EXTCAL_MONTH.' '._MD_EXTCAL_ORDER_BY_DESC); |
|
| 187 | 187 | |
| 188 | - $select->addOption('event_title ASC', _MD_EXTCAL_ALPHA . ' ' . _MD_EXTCAL_ORDER_BY_ASC); |
|
| 189 | - $select->addOption('event_title DESC', _MD_EXTCAL_ALPHA . ' ' . _MD_EXTCAL_ORDER_BY_DESC); |
|
| 188 | + $select->addOption('event_title ASC', _MD_EXTCAL_ALPHA.' '._MD_EXTCAL_ORDER_BY_ASC); |
|
| 189 | + $select->addOption('event_title DESC', _MD_EXTCAL_ALPHA.' '._MD_EXTCAL_ORDER_BY_DESC); |
|
| 190 | 190 | |
| 191 | - $select->addOption('cat_name ASC', _MD_EXTCAL_CATEGORY . ' ' . _MD_EXTCAL_ORDER_BY_ASC); |
|
| 192 | - $select->addOption('cat_name DESC', _MD_EXTCAL_CATEGORY . ' ' . _MD_EXTCAL_ORDER_BY_DESC); |
|
| 191 | + $select->addOption('cat_name ASC', _MD_EXTCAL_CATEGORY.' '._MD_EXTCAL_ORDER_BY_ASC); |
|
| 192 | + $select->addOption('cat_name DESC', _MD_EXTCAL_CATEGORY.' '._MD_EXTCAL_ORDER_BY_DESC); |
|
| 193 | 193 | |
| 194 | 194 | return $select; |
| 195 | 195 | } |
@@ -303,7 +303,7 @@ discard block |
||
| 303 | 303 | function echoDateArray($period) |
| 304 | 304 | { |
| 305 | 305 | foreach ($period as $dt) { |
| 306 | - echo $dt->format("l Y-m-d H:i:s\n") . '<br>'; |
|
| 306 | + echo $dt->format("l Y-m-d H:i:s\n").'<br>'; |
|
| 307 | 307 | } |
| 308 | 308 | } |
| 309 | 309 | |
@@ -319,7 +319,7 @@ discard block |
||
| 319 | 319 | } |
| 320 | 320 | |
| 321 | 321 | $txt = print_r($t, true); |
| 322 | - echo '<pre>Number of items: ' . count($t) . "<br>{$txt}</pre>"; |
|
| 322 | + echo '<pre>Number of items: '.count($t)."<br>{$txt}</pre>"; |
|
| 323 | 323 | } |
| 324 | 324 | |
| 325 | 325 | /*****************************************************************/ |
@@ -332,7 +332,7 @@ discard block |
||
| 332 | 332 | if ('' != $msg) { |
| 333 | 333 | echo "<hr>{$msg}<hr>"; |
| 334 | 334 | } |
| 335 | - echo $line . '<br>'; |
|
| 335 | + echo $line.'<br>'; |
|
| 336 | 336 | } |
| 337 | 337 | |
| 338 | 338 | /*****************************************************************/ |
@@ -359,7 +359,7 @@ discard block |
||
| 359 | 359 | echo "<hr>{$msg}<hr>"; |
| 360 | 360 | } |
| 361 | 361 | |
| 362 | - echo 'date --->' . $tsName . ' = ' . $ts . ' - ' . date('d-m-Y H:m:s', $ts) . '<br>'; |
|
| 362 | + echo 'date --->'.$tsName.' = '.$ts.' - '.date('d-m-Y H:m:s', $ts).'<br>'; |
|
| 363 | 363 | } |
| 364 | 364 | |
| 365 | 365 | /*****************************************************************/ |
@@ -21,49 +21,49 @@ |
||
| 21 | 21 | $moduleDirName = basename(dirname(dirname(__DIR__))); |
| 22 | 22 | $moduleDirNameUpper = strtoupper($moduleDirName); |
| 23 | 23 | |
| 24 | -define('CO_' . $moduleDirNameUpper . '_GDLIBSTATUS', 'GD library support: '); |
|
| 25 | -define('CO_' . $moduleDirNameUpper . '_GDLIBVERSION', 'GD Library version: '); |
|
| 26 | -define('CO_' . $moduleDirNameUpper . '_GDOFF', "<span style='font-weight: bold;'>Disabled</span> (No thumbnails available)"); |
|
| 27 | -define('CO_' . $moduleDirNameUpper . '_GDON', "<span style='font-weight: bold;'>Enabled</span> (Thumbsnails available)"); |
|
| 28 | -define('CO_' . $moduleDirNameUpper . '_IMAGEINFO', 'Server status'); |
|
| 29 | -define('CO_' . $moduleDirNameUpper . '_MAXPOSTSIZE', 'Max post size permitted (post_max_size directive in php.ini): '); |
|
| 30 | -define('CO_' . $moduleDirNameUpper . '_MAXUPLOADSIZE', 'Max upload size permitted (upload_max_filesize directive in php.ini): '); |
|
| 31 | -define('CO_' . $moduleDirNameUpper . '_MEMORYLIMIT', 'Memory limit (memory_limit directive in php.ini): '); |
|
| 32 | -define('CO_' . $moduleDirNameUpper . '_METAVERSION', "<span style='font-weight: bold;'>Downloads meta version:</span> "); |
|
| 33 | -define('CO_' . $moduleDirNameUpper . '_OFF', "<span style='font-weight: bold;'>OFF</span>"); |
|
| 34 | -define('CO_' . $moduleDirNameUpper . '_ON', "<span style='font-weight: bold;'>ON</span>"); |
|
| 35 | -define('CO_' . $moduleDirNameUpper . '_SERVERPATH', 'Server path to XOOPS root: '); |
|
| 36 | -define('CO_' . $moduleDirNameUpper . '_SERVERUPLOADSTATUS', 'Server uploads status: '); |
|
| 37 | -define('CO_' . $moduleDirNameUpper . '_SPHPINI', "<span style='font-weight: bold;'>Information taken from PHP ini file:</span>"); |
|
| 38 | -define('CO_' . $moduleDirNameUpper . '_UPLOADPATHDSC', 'Note. Upload path *MUST* contain the full server path of your upload folder.'); |
|
| 24 | +define('CO_'.$moduleDirNameUpper.'_GDLIBSTATUS', 'GD library support: '); |
|
| 25 | +define('CO_'.$moduleDirNameUpper.'_GDLIBVERSION', 'GD Library version: '); |
|
| 26 | +define('CO_'.$moduleDirNameUpper.'_GDOFF', "<span style='font-weight: bold;'>Disabled</span> (No thumbnails available)"); |
|
| 27 | +define('CO_'.$moduleDirNameUpper.'_GDON', "<span style='font-weight: bold;'>Enabled</span> (Thumbsnails available)"); |
|
| 28 | +define('CO_'.$moduleDirNameUpper.'_IMAGEINFO', 'Server status'); |
|
| 29 | +define('CO_'.$moduleDirNameUpper.'_MAXPOSTSIZE', 'Max post size permitted (post_max_size directive in php.ini): '); |
|
| 30 | +define('CO_'.$moduleDirNameUpper.'_MAXUPLOADSIZE', 'Max upload size permitted (upload_max_filesize directive in php.ini): '); |
|
| 31 | +define('CO_'.$moduleDirNameUpper.'_MEMORYLIMIT', 'Memory limit (memory_limit directive in php.ini): '); |
|
| 32 | +define('CO_'.$moduleDirNameUpper.'_METAVERSION', "<span style='font-weight: bold;'>Downloads meta version:</span> "); |
|
| 33 | +define('CO_'.$moduleDirNameUpper.'_OFF', "<span style='font-weight: bold;'>OFF</span>"); |
|
| 34 | +define('CO_'.$moduleDirNameUpper.'_ON', "<span style='font-weight: bold;'>ON</span>"); |
|
| 35 | +define('CO_'.$moduleDirNameUpper.'_SERVERPATH', 'Server path to XOOPS root: '); |
|
| 36 | +define('CO_'.$moduleDirNameUpper.'_SERVERUPLOADSTATUS', 'Server uploads status: '); |
|
| 37 | +define('CO_'.$moduleDirNameUpper.'_SPHPINI', "<span style='font-weight: bold;'>Information taken from PHP ini file:</span>"); |
|
| 38 | +define('CO_'.$moduleDirNameUpper.'_UPLOADPATHDSC', 'Note. Upload path *MUST* contain the full server path of your upload folder.'); |
|
| 39 | 39 | |
| 40 | -define('CO_' . $moduleDirNameUpper . '_PRINT', "<span style='font-weight: bold;'>Print</span>"); |
|
| 41 | -define('CO_' . $moduleDirNameUpper . '_PDF', "<span style='font-weight: bold;'>Create PDF</span>"); |
|
| 40 | +define('CO_'.$moduleDirNameUpper.'_PRINT', "<span style='font-weight: bold;'>Print</span>"); |
|
| 41 | +define('CO_'.$moduleDirNameUpper.'_PDF', "<span style='font-weight: bold;'>Create PDF</span>"); |
|
| 42 | 42 | |
| 43 | -define('CO_' . $moduleDirNameUpper . '_UPGRADEFAILED0', "Update failed - couldn't rename field '%s'"); |
|
| 44 | -define('CO_' . $moduleDirNameUpper . '_UPGRADEFAILED1', "Update failed - couldn't add new fields"); |
|
| 45 | -define('CO_' . $moduleDirNameUpper . '_UPGRADEFAILED2', "Update failed - couldn't rename table '%s'"); |
|
| 46 | -define('CO_' . $moduleDirNameUpper . '_ERROR_COLUMN', 'Could not create column in database : %s'); |
|
| 47 | -define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_XOOPS', 'This module requires XOOPS %s+ (%s installed)'); |
|
| 48 | -define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_PHP', 'This module requires PHP version %s+ (%s installed)'); |
|
| 49 | -define('CO_' . $moduleDirNameUpper . '_ERROR_TAG_REMOVAL', 'Could not remove tags from Tag Module'); |
|
| 43 | +define('CO_'.$moduleDirNameUpper.'_UPGRADEFAILED0', "Update failed - couldn't rename field '%s'"); |
|
| 44 | +define('CO_'.$moduleDirNameUpper.'_UPGRADEFAILED1', "Update failed - couldn't add new fields"); |
|
| 45 | +define('CO_'.$moduleDirNameUpper.'_UPGRADEFAILED2', "Update failed - couldn't rename table '%s'"); |
|
| 46 | +define('CO_'.$moduleDirNameUpper.'_ERROR_COLUMN', 'Could not create column in database : %s'); |
|
| 47 | +define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_XOOPS', 'This module requires XOOPS %s+ (%s installed)'); |
|
| 48 | +define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_PHP', 'This module requires PHP version %s+ (%s installed)'); |
|
| 49 | +define('CO_'.$moduleDirNameUpper.'_ERROR_TAG_REMOVAL', 'Could not remove tags from Tag Module'); |
|
| 50 | 50 | |
| 51 | -define('CO_' . $moduleDirNameUpper . '_FOLDERS_DELETED_OK', 'Upload Folders have been deleted'); |
|
| 51 | +define('CO_'.$moduleDirNameUpper.'_FOLDERS_DELETED_OK', 'Upload Folders have been deleted'); |
|
| 52 | 52 | |
| 53 | 53 | // Error Msgs |
| 54 | -define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_DEL_PATH', 'Could not delete %s directory'); |
|
| 55 | -define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_REMOVE', 'Could not delete %s'); |
|
| 56 | -define('CO_' . $moduleDirNameUpper . '_ERROR_NO_PLUGIN', 'Could not load plugin'); |
|
| 54 | +define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_DEL_PATH', 'Could not delete %s directory'); |
|
| 55 | +define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_REMOVE', 'Could not delete %s'); |
|
| 56 | +define('CO_'.$moduleDirNameUpper.'_ERROR_NO_PLUGIN', 'Could not load plugin'); |
|
| 57 | 57 | |
| 58 | 58 | //Help |
| 59 | -define('CO_' . $moduleDirNameUpper . '_DIRNAME', basename(dirname(dirname(__DIR__)))); |
|
| 60 | -define('CO_' . $moduleDirNameUpper . '_HELP_HEADER', __DIR__ . '/help/helpheader.tpl'); |
|
| 61 | -define('CO_' . $moduleDirNameUpper . '_BACK_2_ADMIN', 'Back to Administration of '); |
|
| 62 | -define('CO_' . $moduleDirNameUpper . '_OVERVIEW', 'Overview'); |
|
| 59 | +define('CO_'.$moduleDirNameUpper.'_DIRNAME', basename(dirname(dirname(__DIR__)))); |
|
| 60 | +define('CO_'.$moduleDirNameUpper.'_HELP_HEADER', __DIR__.'/help/helpheader.tpl'); |
|
| 61 | +define('CO_'.$moduleDirNameUpper.'_BACK_2_ADMIN', 'Back to Administration of '); |
|
| 62 | +define('CO_'.$moduleDirNameUpper.'_OVERVIEW', 'Overview'); |
|
| 63 | 63 | |
| 64 | 64 | //define('CO_' . $moduleDirNameUpper . '_HELP_DIR', __DIR__); |
| 65 | 65 | |
| 66 | 66 | //help multi-page |
| 67 | -define('CO_' . $moduleDirNameUpper . '_DISCLAIMER', 'Disclaimer'); |
|
| 68 | -define('CO_' . $moduleDirNameUpper . '_LICENSE', 'License'); |
|
| 69 | -define('CO_' . $moduleDirNameUpper . '_SUPPORT', 'Support'); |
|
| 67 | +define('CO_'.$moduleDirNameUpper.'_DISCLAIMER', 'Disclaimer'); |
|
| 68 | +define('CO_'.$moduleDirNameUpper.'_LICENSE', 'License'); |
|
| 69 | +define('CO_'.$moduleDirNameUpper.'_SUPPORT', 'Support'); |
|
@@ -40,13 +40,13 @@ discard block |
||
| 40 | 40 | //check for minimum XOOPS version |
| 41 | 41 | $currentVer = substr(XOOPS_VERSION, 6); // get the numeric part of string |
| 42 | 42 | if (null === $requiredVer) { |
| 43 | - $requiredVer = '' . $module->getInfo('min_xoops'); //making sure it's a string |
|
| 43 | + $requiredVer = ''.$module->getInfo('min_xoops'); //making sure it's a string |
|
| 44 | 44 | } |
| 45 | 45 | $success = true; |
| 46 | 46 | |
| 47 | 47 | if (version_compare($currentVer, $requiredVer, '<')) { |
| 48 | 48 | $success = false; |
| 49 | - $module->setErrors(sprintf(constant('CO_' . $moduleDirNameUpper . '_ERROR_BAD_XOOPS'), $requiredVer, $currentVer)); |
|
| 49 | + $module->setErrors(sprintf(constant('CO_'.$moduleDirNameUpper.'_ERROR_BAD_XOOPS'), $requiredVer, $currentVer)); |
|
| 50 | 50 | } |
| 51 | 51 | |
| 52 | 52 | return $success; |
@@ -70,7 +70,7 @@ discard block |
||
| 70 | 70 | $reqVer = $module->getInfo('min_php'); |
| 71 | 71 | if (false !== $reqVer && '' !== $reqVer) { |
| 72 | 72 | if (version_compare($verNum, $reqVer, '<')) { |
| 73 | - $module->setErrors(sprintf(constant('CO_' . $moduleDirNameUpper . '_ERROR_BAD_PHP'), $reqVer, $verNum)); |
|
| 73 | + $module->setErrors(sprintf(constant('CO_'.$moduleDirNameUpper.'_ERROR_BAD_PHP'), $reqVer, $verNum)); |
|
| 74 | 74 | $success = false; |
| 75 | 75 | } |
| 76 | 76 | } |