@@ -40,13 +40,13 @@ discard block |
||
| 40 | 40 | //check for minimum XOOPS version |
| 41 | 41 | $currentVer = mb_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; |
@@ -77,7 +77,7 @@ discard block |
||
| 77 | 77 | |
| 78 | 78 | if (false !== $reqVer && '' !== $reqVer) { |
| 79 | 79 | if (\version_compare($verNum, $reqVer, '<')) { |
| 80 | - $module->setErrors(\sprintf(\constant('CO_' . $moduleDirNameUpper . '_ERROR_BAD_PHP'), $reqVer, $verNum)); |
|
| 80 | + $module->setErrors(\sprintf(\constant('CO_'.$moduleDirNameUpper.'_ERROR_BAD_PHP'), $reqVer, $verNum)); |
|
| 81 | 81 | $success = false; |
| 82 | 82 | } |
| 83 | 83 | } |
@@ -101,7 +101,7 @@ discard block |
||
| 101 | 101 | $moduleDirName = \basename(\dirname(__DIR__, 2)); |
| 102 | 102 | $moduleDirNameUpper = \mb_strtoupper($moduleDirName); |
| 103 | 103 | $update = ''; |
| 104 | - $repository = 'XoopsModules25x/' . $moduleDirName; |
|
| 104 | + $repository = 'XoopsModules25x/'.$moduleDirName; |
|
| 105 | 105 | // $repository = 'XoopsModules25x/publisher'; //for testing only |
| 106 | 106 | $ret = ''; |
| 107 | 107 | $infoReleasesUrl = "https://api.github.com/repos/$repository/releases"; |
@@ -115,14 +115,14 @@ discard block |
||
| 115 | 115 | if (false === $curlReturn) { |
| 116 | 116 | \trigger_error(\curl_error($curlHandle)); |
| 117 | 117 | } elseif (false !== \mb_strpos($curlReturn, 'Not Found')) { |
| 118 | - \trigger_error('Repository Not Found: ' . $infoReleasesUrl); |
|
| 118 | + \trigger_error('Repository Not Found: '.$infoReleasesUrl); |
|
| 119 | 119 | } else { |
| 120 | 120 | $file = json_decode($curlReturn, false); |
| 121 | 121 | $latestVersionLink = \sprintf("https://github.com/$repository/archive/%s.zip", $file ? \reset($file)->tag_name : $default); |
| 122 | 122 | $latestVersion = $file[0]->tag_name; |
| 123 | 123 | $prerelease = $file[0]->prerelease; |
| 124 | 124 | if ('master' !== $latestVersionLink) { |
| 125 | - $update = \constant('CO_' . $moduleDirNameUpper . '_' . 'NEW_VERSION') . $latestVersion; |
|
| 125 | + $update = \constant('CO_'.$moduleDirNameUpper.'_'.'NEW_VERSION').$latestVersion; |
|
| 126 | 126 | } |
| 127 | 127 | //"PHP-standardized" version |
| 128 | 128 | $latestVersion = mb_strtolower($latestVersion); |
@@ -130,7 +130,7 @@ discard block |
||
| 130 | 130 | $latestVersion = \str_replace('_', '', mb_strtolower($latestVersion)); |
| 131 | 131 | $latestVersion = \str_replace('final', '', mb_strtolower($latestVersion)); |
| 132 | 132 | } |
| 133 | - $moduleVersion = ($helper->getModule()->getInfo('version') . '_' . $helper->getModule()->getInfo('module_status')); |
|
| 133 | + $moduleVersion = ($helper->getModule()->getInfo('version').'_'.$helper->getModule()->getInfo('module_status')); |
|
| 134 | 134 | //"PHP-standardized" version |
| 135 | 135 | $moduleVersion = \str_replace(' ', '', mb_strtolower($moduleVersion)); |
| 136 | 136 | // $moduleVersion = '1.0'; //for testing only |
@@ -18,7 +18,7 @@ |
||
| 18 | 18 | * @author Trabis <[email protected]> |
| 19 | 19 | * @author Hossein Azizabadi (AKA Voltan) |
| 20 | 20 | */ |
| 21 | -require_once __DIR__ . '/header.php'; |
|
| 21 | +require_once __DIR__.'/header.php'; |
|
| 22 | 22 | /** @var ContactHandler $contactHandler */ |
| 23 | 23 | |
| 24 | 24 | if (!empty($_POST)) { |
@@ -21,9 +21,9 @@ discard block |
||
| 21 | 21 | /** @var Admin $adminObject */ |
| 22 | 22 | /** @var Helper $helper */ |
| 23 | 23 | |
| 24 | -require __DIR__ . '/admin_header.php'; |
|
| 24 | +require __DIR__.'/admin_header.php'; |
|
| 25 | 25 | |
| 26 | -require_once XOOPS_ROOT_PATH . '/class/xoopsformloader.php'; |
|
| 26 | +require_once XOOPS_ROOT_PATH.'/class/xoopsformloader.php'; |
|
| 27 | 27 | |
| 28 | 28 | $moduleDirName = basename(dirname(__DIR__)); |
| 29 | 29 | $moduleDirNameUpper = mb_strtoupper($moduleDirName); //$capsDirName |
@@ -48,9 +48,9 @@ discard block |
||
| 48 | 48 | ] |
| 49 | 49 | ); |
| 50 | 50 | $form->addElement($sideSelect); |
| 51 | -$form->addElement(new \XoopsFormText(constant('CO_' . $moduleDirNameUpper . '_' . 'WEIGHT'), 'bweight', 2, 5, $block['weight'])); |
|
| 52 | -$form->addElement(new \XoopsFormRadioYN(constant('CO_' . $moduleDirNameUpper . '_' . 'VISIBLE'), 'bvisible', $block['visible'])); |
|
| 53 | -$moduleSelect = new \XoopsFormSelect(constant('CO_' . $moduleDirNameUpper . '_' . 'VISIBLEIN'), 'bmodule', $block['modules'], 5, true); |
|
| 51 | +$form->addElement(new \XoopsFormText(constant('CO_'.$moduleDirNameUpper.'_'.'WEIGHT'), 'bweight', 2, 5, $block['weight'])); |
|
| 52 | +$form->addElement(new \XoopsFormRadioYN(constant('CO_'.$moduleDirNameUpper.'_'.'VISIBLE'), 'bvisible', $block['visible'])); |
|
| 53 | +$moduleSelect = new \XoopsFormSelect(constant('CO_'.$moduleDirNameUpper.'_'.'VISIBLEIN'), 'bmodule', $block['modules'], 5, true); |
|
| 54 | 54 | /** @var \XoopsModuleHandler $moduleHandler */ |
| 55 | 55 | $moduleHandler = xoops_getHandler('module'); |
| 56 | 56 | $criteria = new \CriteriaCompo(new \Criteria('hasmain', 1)); |
@@ -61,10 +61,10 @@ discard block |
||
| 61 | 61 | ksort($moduleList); |
| 62 | 62 | $moduleSelect->addOptionArray($moduleList); |
| 63 | 63 | $form->addElement($moduleSelect); |
| 64 | -$form->addElement(new \XoopsFormText(constant('CO_' . $moduleDirNameUpper . '_' . 'TITLE'), 'btitle', 50, 255, $block['title']), false); |
|
| 64 | +$form->addElement(new \XoopsFormText(constant('CO_'.$moduleDirNameUpper.'_'.'TITLE'), 'btitle', 50, 255, $block['title']), false); |
|
| 65 | 65 | if ($block['is_custom']) { |
| 66 | 66 | $textarea = new \XoopsFormDhtmlTextArea(_AM_SYSTEM_BLOCKS_CONTENT, 'bcontent', $block['content'], 15, 70); |
| 67 | - $textarea->setDescription('<span style="font-size:x-small;font-weight:bold;">' . _AM_SYSTEM_BLOCKS_USEFULTAGS . '</span><br><span style="font-size:x-small;font-weight:normal;">' . sprintf(_AM_BLOCKTAG1, '{X_SITEURL}', XOOPS_URL . '/') . '</span>'); |
|
| 67 | + $textarea->setDescription('<span style="font-size:x-small;font-weight:bold;">'._AM_SYSTEM_BLOCKS_USEFULTAGS.'</span><br><span style="font-size:x-small;font-weight:normal;">'.sprintf(_AM_BLOCKTAG1, '{X_SITEURL}', XOOPS_URL.'/').'</span>'); |
|
| 68 | 68 | $form->addElement($textarea, true); |
| 69 | 69 | $ctypeSelect = new \XoopsFormSelect(_AM_SYSTEM_BLOCKS_CTYPE, 'bctype', $block['ctype']); |
| 70 | 70 | $ctypeSelect->addOptionArray( |
@@ -82,11 +82,11 @@ discard block |
||
| 82 | 82 | $tplfileHandler = xoops_getHandler('tplfile'); |
| 83 | 83 | $btemplate = $tplfileHandler->find($GLOBALS['xoopsConfig']['template_set'], 'block', $block['bid']); |
| 84 | 84 | if (count($btemplate) > 0) { |
| 85 | - $form->addElement(new \XoopsFormLabel(_AM_SYSTEM_BLOCKS_CONTENT, '<a href="' . XOOPS_URL . '/modules/system/admin.php?fct=tplsets&op=edittpl&id=' . $btemplate[0]->getVar('tpl_id') . '">' . _AM_SYSTEM_BLOCKS_EDITTPL . '</a>')); |
|
| 85 | + $form->addElement(new \XoopsFormLabel(_AM_SYSTEM_BLOCKS_CONTENT, '<a href="'.XOOPS_URL.'/modules/system/admin.php?fct=tplsets&op=edittpl&id='.$btemplate[0]->getVar('tpl_id').'">'._AM_SYSTEM_BLOCKS_EDITTPL.'</a>')); |
|
| 86 | 86 | } else { |
| 87 | 87 | $btemplate2 = $tplfileHandler->find('default', 'block', $block['bid']); |
| 88 | 88 | if (count($btemplate2) > 0) { |
| 89 | - $form->addElement(new \XoopsFormLabel(_AM_SYSTEM_BLOCKS_CONTENT, '<a href="' . XOOPS_URL . '/modules/system/admin.php?fct=tplsets&op=edittpl&id=' . $btemplate2[0]->getVar('tpl_id') . '" target="_blank">' . _AM_SYSTEM_BLOCKS_EDITTPL . '</a>')); |
|
| 89 | + $form->addElement(new \XoopsFormLabel(_AM_SYSTEM_BLOCKS_CONTENT, '<a href="'.XOOPS_URL.'/modules/system/admin.php?fct=tplsets&op=edittpl&id='.$btemplate2[0]->getVar('tpl_id').'" target="_blank">'._AM_SYSTEM_BLOCKS_EDITTPL.'</a>')); |
|
| 90 | 90 | } |
| 91 | 91 | } |
| 92 | 92 | } |
@@ -88,28 +88,28 @@ discard block |
||
| 88 | 88 | echo $GLOBALS['xoopsSecurity']->getTokenHTML(); |
| 89 | 89 | echo "<table width='100%' class='outer' cellpadding='4' cellspacing='1'> |
| 90 | 90 | <tr valign='middle'><th align='center'>" |
| 91 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'TITLE') |
|
| 92 | - . "</th><th align='center' nowrap='nowrap'>" |
|
| 93 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'SIDE') |
|
| 94 | - . '<br>' |
|
| 95 | - . _LEFT |
|
| 96 | - . '-' |
|
| 97 | - . _CENTER |
|
| 98 | - . '-' |
|
| 99 | - . _RIGHT |
|
| 100 | - . "</th><th align='center'>" |
|
| 101 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'WEIGHT') |
|
| 102 | - . "</th><th align='center'>" |
|
| 103 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'VISIBLE') |
|
| 104 | - . "</th><th align='center'>" |
|
| 105 | - . _AM_SYSTEM_BLOCKS_VISIBLEIN |
|
| 106 | - . "</th><th align='center'>" |
|
| 107 | - . _AM_SYSTEM_ADGS |
|
| 108 | - . "</th><th align='center'>" |
|
| 109 | - . _AM_SYSTEM_BLOCKS_BCACHETIME |
|
| 110 | - . "</th><th align='center'>" |
|
| 111 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'ACTION') |
|
| 112 | - . '</th></tr> |
|
| 91 | + . constant('CO_' . $moduleDirNameUpper . '_' . 'TITLE') |
|
| 92 | + . "</th><th align='center' nowrap='nowrap'>" |
|
| 93 | + . constant('CO_' . $moduleDirNameUpper . '_' . 'SIDE') |
|
| 94 | + . '<br>' |
|
| 95 | + . _LEFT |
|
| 96 | + . '-' |
|
| 97 | + . _CENTER |
|
| 98 | + . '-' |
|
| 99 | + . _RIGHT |
|
| 100 | + . "</th><th align='center'>" |
|
| 101 | + . constant('CO_' . $moduleDirNameUpper . '_' . 'WEIGHT') |
|
| 102 | + . "</th><th align='center'>" |
|
| 103 | + . constant('CO_' . $moduleDirNameUpper . '_' . 'VISIBLE') |
|
| 104 | + . "</th><th align='center'>" |
|
| 105 | + . _AM_SYSTEM_BLOCKS_VISIBLEIN |
|
| 106 | + . "</th><th align='center'>" |
|
| 107 | + . _AM_SYSTEM_ADGS |
|
| 108 | + . "</th><th align='center'>" |
|
| 109 | + . _AM_SYSTEM_BLOCKS_BCACHETIME |
|
| 110 | + . "</th><th align='center'>" |
|
| 111 | + . constant('CO_' . $moduleDirNameUpper . '_' . 'ACTION') |
|
| 112 | + . '</th></tr> |
|
| 113 | 113 | '; |
| 114 | 114 | $blockArray = \XoopsBlock::getByModule($xoopsModule->mid()); |
| 115 | 115 | $blockCount = count($blockArray); |
@@ -175,69 +175,69 @@ discard block |
||
| 175 | 175 | } |
| 176 | 176 | $name = $i->getVar('name'); |
| 177 | 177 | echo "<tr valign='top'><td class='$class' align='center'><input type='text' name='title[" |
| 178 | - . $i->getVar('bid') |
|
| 179 | - . "]' value='" |
|
| 180 | - . $title |
|
| 181 | - . "'></td><td class='$class' align='center' nowrap='nowrap'> |
|
| 178 | + . $i->getVar('bid') |
|
| 179 | + . "]' value='" |
|
| 180 | + . $title |
|
| 181 | + . "'></td><td class='$class' align='center' nowrap='nowrap'> |
|
| 182 | 182 | <div align='center' > |
| 183 | 183 | <input type='radio' name='side[" |
| 184 | - . $i->getVar('bid') |
|
| 185 | - . "]' value='" |
|
| 186 | - . XOOPS_CENTERBLOCK_LEFT |
|
| 187 | - . "'$ssel2> |
|
| 184 | + . $i->getVar('bid') |
|
| 185 | + . "]' value='" |
|
| 186 | + . XOOPS_CENTERBLOCK_LEFT |
|
| 187 | + . "'$ssel2> |
|
| 188 | 188 | <input type='radio' name='side[" |
| 189 | - . $i->getVar('bid') |
|
| 190 | - . "]' value='" |
|
| 191 | - . XOOPS_CENTERBLOCK_CENTER |
|
| 192 | - . "'$ssel3> |
|
| 189 | + . $i->getVar('bid') |
|
| 190 | + . "]' value='" |
|
| 191 | + . XOOPS_CENTERBLOCK_CENTER |
|
| 192 | + . "'$ssel3> |
|
| 193 | 193 | <input type='radio' name='side[" |
| 194 | - . $i->getVar('bid') |
|
| 195 | - . "]' value='" |
|
| 196 | - . XOOPS_CENTERBLOCK_RIGHT |
|
| 197 | - . "'$ssel4> |
|
| 194 | + . $i->getVar('bid') |
|
| 195 | + . "]' value='" |
|
| 196 | + . XOOPS_CENTERBLOCK_RIGHT |
|
| 197 | + . "'$ssel4> |
|
| 198 | 198 | </div> |
| 199 | 199 | <div> |
| 200 | 200 | <span style='float:right;'><input type='radio' name='side[" |
| 201 | - . $i->getVar('bid') |
|
| 202 | - . "]' value='" |
|
| 203 | - . XOOPS_SIDEBLOCK_RIGHT |
|
| 204 | - . "'$ssel1></span> |
|
| 201 | + . $i->getVar('bid') |
|
| 202 | + . "]' value='" |
|
| 203 | + . XOOPS_SIDEBLOCK_RIGHT |
|
| 204 | + . "'$ssel1></span> |
|
| 205 | 205 | <div align='left'><input type='radio' name='side[" |
| 206 | - . $i->getVar('bid') |
|
| 207 | - . "]' value='" |
|
| 208 | - . XOOPS_SIDEBLOCK_LEFT |
|
| 209 | - . "'$ssel0></div> |
|
| 206 | + . $i->getVar('bid') |
|
| 207 | + . "]' value='" |
|
| 208 | + . XOOPS_SIDEBLOCK_LEFT |
|
| 209 | + . "'$ssel0></div> |
|
| 210 | 210 | </div> |
| 211 | 211 | <div align='center'> |
| 212 | 212 | <input type='radio' name='side[" |
| 213 | - . $i->getVar('bid') |
|
| 214 | - . "]' value='" |
|
| 215 | - . XOOPS_CENTERBLOCK_BOTTOMLEFT |
|
| 216 | - . "'$ssel5> |
|
| 213 | + . $i->getVar('bid') |
|
| 214 | + . "]' value='" |
|
| 215 | + . XOOPS_CENTERBLOCK_BOTTOMLEFT |
|
| 216 | + . "'$ssel5> |
|
| 217 | 217 | <input type='radio' name='side[" |
| 218 | - . $i->getVar('bid') |
|
| 219 | - . "]' value='" |
|
| 220 | - . XOOPS_CENTERBLOCK_BOTTOM |
|
| 221 | - . "'$ssel7> |
|
| 218 | + . $i->getVar('bid') |
|
| 219 | + . "]' value='" |
|
| 220 | + . XOOPS_CENTERBLOCK_BOTTOM |
|
| 221 | + . "'$ssel7> |
|
| 222 | 222 | <input type='radio' name='side[" |
| 223 | - . $i->getVar('bid') |
|
| 224 | - . "]' value='" |
|
| 225 | - . XOOPS_CENTERBLOCK_BOTTOMRIGHT |
|
| 226 | - . "'$ssel6> |
|
| 223 | + . $i->getVar('bid') |
|
| 224 | + . "]' value='" |
|
| 225 | + . XOOPS_CENTERBLOCK_BOTTOMRIGHT |
|
| 226 | + . "'$ssel6> |
|
| 227 | 227 | </div> |
| 228 | 228 | </td><td class='$class' align='center'><input type='text' name='weight[" |
| 229 | - . $i->getVar('bid') |
|
| 230 | - . "]' value='" |
|
| 231 | - . $i->getVar('weight') |
|
| 232 | - . "' size='5' maxlength='5'></td><td class='$class' align='center' nowrap><input type='radio' name='visible[" |
|
| 233 | - . $i->getVar('bid') |
|
| 234 | - . "]' value='1'$sel1>" |
|
| 235 | - . _YES |
|
| 236 | - . " <input type='radio' name='visible[" |
|
| 237 | - . $i->getVar('bid') |
|
| 238 | - . "]' value='0'$sel0>" |
|
| 239 | - . _NO |
|
| 240 | - . '</td>'; |
|
| 229 | + . $i->getVar('bid') |
|
| 230 | + . "]' value='" |
|
| 231 | + . $i->getVar('weight') |
|
| 232 | + . "' size='5' maxlength='5'></td><td class='$class' align='center' nowrap><input type='radio' name='visible[" |
|
| 233 | + . $i->getVar('bid') |
|
| 234 | + . "]' value='1'$sel1>" |
|
| 235 | + . _YES |
|
| 236 | + . " <input type='radio' name='visible[" |
|
| 237 | + . $i->getVar('bid') |
|
| 238 | + . "]' value='0'$sel0>" |
|
| 239 | + . _NO |
|
| 240 | + . '</td>'; |
|
| 241 | 241 | |
| 242 | 242 | echo "<td class='$class' align='center'><select size='5' name='bmodule[" . $i->getVar('bid') . "][]' id='bmodule[" . $i->getVar('bid') . "][]' multiple='multiple'>"; |
| 243 | 243 | foreach ($moduleList as $k => $v) { |
@@ -21,7 +21,7 @@ discard block |
||
| 21 | 21 | /** @var Admin $adminObject */ |
| 22 | 22 | /** @var Helper $helper */ |
| 23 | 23 | |
| 24 | -require __DIR__ . '/admin_header.php'; |
|
| 24 | +require __DIR__.'/admin_header.php'; |
|
| 25 | 25 | |
| 26 | 26 | $moduleDirName = basename(dirname(__DIR__)); |
| 27 | 27 | $moduleDirNameUpper = mb_strtoupper($moduleDirName); //$capsDirName |
@@ -30,10 +30,10 @@ discard block |
||
| 30 | 30 | |
| 31 | 31 | if (!is_object($GLOBALS['xoopsUser']) || !is_object($xoopsModule) |
| 32 | 32 | || !$GLOBALS['xoopsUser']->isAdmin($xoopsModule->mid())) { |
| 33 | - exit(constant('CO_' . $moduleDirNameUpper . '_' . 'ERROR403')); |
|
| 33 | + exit(constant('CO_'.$moduleDirNameUpper.'_'.'ERROR403')); |
|
| 34 | 34 | } |
| 35 | 35 | if ($GLOBALS['xoopsUser']->isAdmin($xoopsModule->mid())) { |
| 36 | - require_once XOOPS_ROOT_PATH . '/class/xoopsblock.php'; |
|
| 36 | + require_once XOOPS_ROOT_PATH.'/class/xoopsblock.php'; |
|
| 37 | 37 | $op = 'list'; |
| 38 | 38 | if (isset($_POST)) { |
| 39 | 39 | foreach ($_POST as $k => $v) { |
@@ -57,7 +57,7 @@ discard block |
||
| 57 | 57 | function listBlocks() |
| 58 | 58 | { |
| 59 | 59 | global $xoopsModule, $pathIcon16; |
| 60 | - require_once XOOPS_ROOT_PATH . '/class/xoopslists.php'; |
|
| 60 | + require_once XOOPS_ROOT_PATH.'/class/xoopslists.php'; |
|
| 61 | 61 | $moduleDirName = basename(dirname(__DIR__)); |
| 62 | 62 | $moduleDirNameUpper = mb_strtoupper($moduleDirName); //$capsDirName |
| 63 | 63 | $db = \XoopsDatabaseFactory::getDatabaseConnection(); |
@@ -83,14 +83,14 @@ discard block |
||
| 83 | 83 | $moduleList[0] = _AM_SYSTEM_BLOCKS_ALLPAGES; |
| 84 | 84 | ksort($moduleList); |
| 85 | 85 | echo " |
| 86 | - <h4 style='text-align:left;'>" . constant('CO_' . $moduleDirNameUpper . '_' . 'BADMIN') . '</h4>'; |
|
| 87 | - echo "<form action='" . $_SERVER['SCRIPT_NAME'] . "' name='blockadmin' method='post'>"; |
|
| 86 | + <h4 style='text-align:left;'>" . constant('CO_'.$moduleDirNameUpper.'_'.'BADMIN').'</h4>'; |
|
| 87 | + echo "<form action='".$_SERVER['SCRIPT_NAME']."' name='blockadmin' method='post'>"; |
|
| 88 | 88 | echo $GLOBALS['xoopsSecurity']->getTokenHTML(); |
| 89 | 89 | echo "<table width='100%' class='outer' cellpadding='4' cellspacing='1'> |
| 90 | 90 | <tr valign='middle'><th align='center'>" |
| 91 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'TITLE') |
|
| 91 | + . constant('CO_'.$moduleDirNameUpper.'_'.'TITLE') |
|
| 92 | 92 | . "</th><th align='center' nowrap='nowrap'>" |
| 93 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'SIDE') |
|
| 93 | + . constant('CO_'.$moduleDirNameUpper.'_'.'SIDE') |
|
| 94 | 94 | . '<br>' |
| 95 | 95 | . _LEFT |
| 96 | 96 | . '-' |
@@ -98,9 +98,9 @@ discard block |
||
| 98 | 98 | . '-' |
| 99 | 99 | . _RIGHT |
| 100 | 100 | . "</th><th align='center'>" |
| 101 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'WEIGHT') |
|
| 101 | + . constant('CO_'.$moduleDirNameUpper.'_'.'WEIGHT') |
|
| 102 | 102 | . "</th><th align='center'>" |
| 103 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'VISIBLE') |
|
| 103 | + . constant('CO_'.$moduleDirNameUpper.'_'.'VISIBLE') |
|
| 104 | 104 | . "</th><th align='center'>" |
| 105 | 105 | . _AM_SYSTEM_BLOCKS_VISIBLEIN |
| 106 | 106 | . "</th><th align='center'>" |
@@ -108,7 +108,7 @@ discard block |
||
| 108 | 108 | . "</th><th align='center'>" |
| 109 | 109 | . _AM_SYSTEM_BLOCKS_BCACHETIME |
| 110 | 110 | . "</th><th align='center'>" |
| 111 | - . constant('CO_' . $moduleDirNameUpper . '_' . 'ACTION') |
|
| 111 | + . constant('CO_'.$moduleDirNameUpper.'_'.'ACTION') |
|
| 112 | 112 | . '</th></tr> |
| 113 | 113 | '; |
| 114 | 114 | $blockArray = \XoopsBlock::getByModule($xoopsModule->mid()); |
@@ -129,11 +129,11 @@ discard block |
||
| 129 | 129 | ]; |
| 130 | 130 | foreach ($blockArray as $i) { |
| 131 | 131 | $groupsPerms = $grouppermHandler->getGroupIds('block_read', $i->getVar('bid')); |
| 132 | - $sql = 'SELECT module_id FROM ' . $db->prefix('block_module_link') . ' WHERE block_id=' . $i->getVar('bid'); |
|
| 132 | + $sql = 'SELECT module_id FROM '.$db->prefix('block_module_link').' WHERE block_id='.$i->getVar('bid'); |
|
| 133 | 133 | $result = $db->query($sql); |
| 134 | 134 | $modules = []; |
| 135 | 135 | while (false !== ($row = $db->fetchArray($result))) { |
| 136 | - $modules[] = (int)$row['module_id']; |
|
| 136 | + $modules[] = (int) $row['module_id']; |
|
| 137 | 137 | } |
| 138 | 138 | |
| 139 | 139 | $cachetimeOptions = ''; |
@@ -239,47 +239,47 @@ discard block |
||
| 239 | 239 | . _NO |
| 240 | 240 | . '</td>'; |
| 241 | 241 | |
| 242 | - echo "<td class='$class' align='center'><select size='5' name='bmodule[" . $i->getVar('bid') . "][]' id='bmodule[" . $i->getVar('bid') . "][]' multiple='multiple'>"; |
|
| 242 | + echo "<td class='$class' align='center'><select size='5' name='bmodule[".$i->getVar('bid')."][]' id='bmodule[".$i->getVar('bid')."][]' multiple='multiple'>"; |
|
| 243 | 243 | foreach ($moduleList as $k => $v) { |
| 244 | - echo "<option value='$k'" . (in_array($k, $modules) ? 'selected' : '') . ">$v</option>"; |
|
| 244 | + echo "<option value='$k'".(in_array($k, $modules) ? 'selected' : '').">$v</option>"; |
|
| 245 | 245 | } |
| 246 | 246 | echo '</select></td>'; |
| 247 | 247 | |
| 248 | - echo "<td class='$class' align='center'><select size='5' name='groups[" . $i->getVar('bid') . "][]' id='groups[" . $i->getVar('bid') . "][]' multiple='multiple'>"; |
|
| 248 | + echo "<td class='$class' align='center'><select size='5' name='groups[".$i->getVar('bid')."][]' id='groups[".$i->getVar('bid')."][]' multiple='multiple'>"; |
|
| 249 | 249 | foreach ($groups as $grp) { |
| 250 | - echo "<option value='" . $grp->getVar('groupid') . "' " . (in_array($grp->getVar('groupid'), $groupsPerms) ? 'selected' : '') . '>' . $grp->getVar('name') . '</option>'; |
|
| 250 | + echo "<option value='".$grp->getVar('groupid')."' ".(in_array($grp->getVar('groupid'), $groupsPerms) ? 'selected' : '').'>'.$grp->getVar('name').'</option>'; |
|
| 251 | 251 | } |
| 252 | 252 | echo '</select></td>'; |
| 253 | 253 | |
| 254 | 254 | // Cache lifetime |
| 255 | - echo '<td class="' . $class . '" align="center"> <select name="bcachetime[' . $i->getVar('bid') . ']" size="1">' . $cachetimeOptions . '</select> |
|
| 255 | + echo '<td class="'.$class.'" align="center"> <select name="bcachetime['.$i->getVar('bid').']" size="1">'.$cachetimeOptions.'</select> |
|
| 256 | 256 | </td>'; |
| 257 | 257 | |
| 258 | 258 | // Actions |
| 259 | 259 | |
| 260 | - echo "<td class='$class' align='center'><a href='blocksadmin.php?op=edit&bid=" . $i->getVar('bid') . "'><img src=" . $pathIcon16 . '/edit.png' . " alt='" . _EDIT . "' title='" . _EDIT . "'> |
|
| 261 | - </a> <a href='blocksadmin.php?op=clone&bid=" . $i->getVar('bid') . "'><img src=" . $pathIcon16 . '/editcopy.png' . " alt='" . _CLONE . "' title='" . _CLONE . "'> |
|
| 260 | + echo "<td class='$class' align='center'><a href='blocksadmin.php?op=edit&bid=".$i->getVar('bid')."'><img src=".$pathIcon16.'/edit.png'." alt='"._EDIT."' title='"._EDIT."'> |
|
| 261 | + </a> <a href='blocksadmin.php?op=clone&bid=" . $i->getVar('bid')."'><img src=".$pathIcon16.'/editcopy.png'." alt='"._CLONE."' title='"._CLONE."'> |
|
| 262 | 262 | </a>"; |
| 263 | 263 | if ('S' !== $i->getVar('block_type') && 'M' !== $i->getVar('block_type')) { |
| 264 | - echo " <a href='" . XOOPS_URL . '/modules/system/admin.php?fct=blocksadmin&op=delete&bid=' . $i->getVar('bid') . "'><img src=" . $pathIcon16 . '/delete.png' . " alt='" . _DELETE . "' title='" . _DELETE . "'> |
|
| 264 | + echo " <a href='".XOOPS_URL.'/modules/system/admin.php?fct=blocksadmin&op=delete&bid='.$i->getVar('bid')."'><img src=".$pathIcon16.'/delete.png'." alt='"._DELETE."' title='"._DELETE."'> |
|
| 265 | 265 | </a>"; |
| 266 | 266 | } |
| 267 | 267 | echo " |
| 268 | - <input type='hidden' name='oldtitle[" . $i->getVar('bid') . "]' value='" . $i->getVar('title') . "'> |
|
| 269 | - <input type='hidden' name='oldside[" . $i->getVar('bid') . "]' value='" . $i->getVar('side') . "'> |
|
| 270 | - <input type='hidden' name='oldweight[" . $i->getVar('bid') . "]' value='" . $i->getVar('weight') . "'> |
|
| 271 | - <input type='hidden' name='oldvisible[" . $i->getVar('bid') . "]' value='" . $i->getVar('visible') . "'> |
|
| 272 | - <input type='hidden' name='oldgroups[" . $i->getVar('groups') . "]' value='" . $i->getVar('groups') . "'> |
|
| 273 | - <input type='hidden' name='oldbcachetime[" . $i->getVar('bid') . "]' value='" . $i->getVar('bcachetime') . "'> |
|
| 274 | - <input type='hidden' name='bid[" . $i->getVar('bid') . "]' value='" . $i->getVar('bid') . "'> |
|
| 268 | + <input type='hidden' name='oldtitle[" . $i->getVar('bid')."]' value='".$i->getVar('title')."'> |
|
| 269 | + <input type='hidden' name='oldside[" . $i->getVar('bid')."]' value='".$i->getVar('side')."'> |
|
| 270 | + <input type='hidden' name='oldweight[" . $i->getVar('bid')."]' value='".$i->getVar('weight')."'> |
|
| 271 | + <input type='hidden' name='oldvisible[" . $i->getVar('bid')."]' value='".$i->getVar('visible')."'> |
|
| 272 | + <input type='hidden' name='oldgroups[" . $i->getVar('groups')."]' value='".$i->getVar('groups')."'> |
|
| 273 | + <input type='hidden' name='oldbcachetime[" . $i->getVar('bid')."]' value='".$i->getVar('bcachetime')."'> |
|
| 274 | + <input type='hidden' name='bid[" . $i->getVar('bid')."]' value='".$i->getVar('bid')."'> |
|
| 275 | 275 | </td></tr> |
| 276 | 276 | "; |
| 277 | 277 | $class = ('even' === $class) ? 'odd' : 'even'; |
| 278 | 278 | } |
| 279 | 279 | echo "<tr><td class='foot' align='center' colspan='8'> |
| 280 | 280 | <input type='hidden' name='op' value='order'> |
| 281 | - " . $GLOBALS['xoopsSecurity']->getTokenHTML() . " |
|
| 282 | - <input type='submit' name='submit' value='" . _SUBMIT . "'> |
|
| 281 | + " . $GLOBALS['xoopsSecurity']->getTokenHTML()." |
|
| 282 | + <input type='submit' name='submit' value='" . _SUBMIT."'> |
|
| 283 | 283 | </td></tr></table> |
| 284 | 284 | </form> |
| 285 | 285 | <br><br>"; |
@@ -290,7 +290,7 @@ discard block |
||
| 290 | 290 | */ |
| 291 | 291 | function cloneBlock($bid) |
| 292 | 292 | { |
| 293 | - require_once __DIR__ . '/admin_header.php'; |
|
| 293 | + require_once __DIR__.'/admin_header.php'; |
|
| 294 | 294 | |
| 295 | 295 | xoops_cp_header(); |
| 296 | 296 | |
@@ -305,16 +305,16 @@ discard block |
||
| 305 | 305 | // mpu_adm_menu(); |
| 306 | 306 | $myblock = new \XoopsBlock($bid); |
| 307 | 307 | $db = \XoopsDatabaseFactory::getDatabaseConnection(); |
| 308 | - $sql = 'SELECT module_id FROM ' . $db->prefix('block_module_link') . ' WHERE block_id=' . (int)$bid; |
|
| 308 | + $sql = 'SELECT module_id FROM '.$db->prefix('block_module_link').' WHERE block_id='.(int) $bid; |
|
| 309 | 309 | $result = $db->query($sql); |
| 310 | 310 | $modules = []; |
| 311 | 311 | while (false !== ($row = $db->fetchArray($result))) { |
| 312 | - $modules[] = (int)$row['module_id']; |
|
| 312 | + $modules[] = (int) $row['module_id']; |
|
| 313 | 313 | } |
| 314 | 314 | $isCustom = ('C' === $myblock->getVar('block_type') || 'E' === $myblock->getVar('block_type')); |
| 315 | 315 | $block = [ |
| 316 | - 'title' => $myblock->getVar('title') . ' Clone', |
|
| 317 | - 'form_title' => constant('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_CLONEBLOCK'), |
|
| 316 | + 'title' => $myblock->getVar('title').' Clone', |
|
| 317 | + 'form_title' => constant('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_CLONEBLOCK'), |
|
| 318 | 318 | 'name' => $myblock->getVar('name'), |
| 319 | 319 | 'side' => $myblock->getVar('side'), |
| 320 | 320 | 'weight' => $myblock->getVar('weight'), |
@@ -330,12 +330,12 @@ discard block |
||
| 330 | 330 | 'template' => $myblock->getVar('template'), |
| 331 | 331 | 'options' => $myblock->getVar('options'), |
| 332 | 332 | ]; |
| 333 | - echo '<a href="blocksadmin.php">' . constant('CO_' . $moduleDirNameUpper . '_' . 'BADMIN') . '</a> <span style="font-weight:bold;">»»</span> ' . _AM_SYSTEM_BLOCKS_CLONEBLOCK . '<br><br>'; |
|
| 334 | - require_once __DIR__ . '/blockform.php'; |
|
| 333 | + echo '<a href="blocksadmin.php">'.constant('CO_'.$moduleDirNameUpper.'_'.'BADMIN').'</a> <span style="font-weight:bold;">»»</span> '._AM_SYSTEM_BLOCKS_CLONEBLOCK.'<br><br>'; |
|
| 334 | + require_once __DIR__.'/blockform.php'; |
|
| 335 | 335 | /** @var XoopsThemeForm $form */ |
| 336 | 336 | $form->display(); |
| 337 | 337 | // xoops_cp_footer(); |
| 338 | - require_once __DIR__ . '/admin_footer.php'; |
|
| 338 | + require_once __DIR__.'/admin_footer.php'; |
|
| 339 | 339 | exit(); |
| 340 | 340 | } |
| 341 | 341 | |
@@ -398,12 +398,12 @@ discard block |
||
| 398 | 398 | } |
| 399 | 399 | $db = \XoopsDatabaseFactory::getDatabaseConnection(); |
| 400 | 400 | foreach ($bmodule as $bmid) { |
| 401 | - $sql = 'INSERT INTO ' . $db->prefix('block_module_link') . ' (block_id, module_id) VALUES (' . $newid . ', ' . $bmid . ')'; |
|
| 401 | + $sql = 'INSERT INTO '.$db->prefix('block_module_link').' (block_id, module_id) VALUES ('.$newid.', '.$bmid.')'; |
|
| 402 | 402 | $db->query($sql); |
| 403 | 403 | } |
| 404 | 404 | $groups = &$GLOBALS['xoopsUser']->getGroups(); |
| 405 | 405 | foreach ($groups as $iValue) { |
| 406 | - $sql = 'INSERT INTO ' . $db->prefix('group_permission') . ' (gperm_groupid, gperm_itemid, gperm_modid, gperm_name) VALUES (' . $iValue . ', ' . $newid . ", 1, 'block_read')"; |
|
| 406 | + $sql = 'INSERT INTO '.$db->prefix('group_permission').' (gperm_groupid, gperm_itemid, gperm_modid, gperm_name) VALUES ('.$iValue.', '.$newid.", 1, 'block_read')"; |
|
| 407 | 407 | $db->query($sql); |
| 408 | 408 | } |
| 409 | 409 | redirect_header('blocksadmin.php?op=listar', 1, _AM_DBUPDATED); |
@@ -437,7 +437,7 @@ discard block |
||
| 437 | 437 | */ |
| 438 | 438 | function editBlock($bid) |
| 439 | 439 | { |
| 440 | - require_once __DIR__ . '/admin_header.php'; |
|
| 440 | + require_once __DIR__.'/admin_header.php'; |
|
| 441 | 441 | xoops_cp_header(); |
| 442 | 442 | $adminObject = Admin::getInstance(); |
| 443 | 443 | $adminObject->displayNavigation(basename(__FILE__)); |
@@ -449,16 +449,16 @@ discard block |
||
| 449 | 449 | // mpu_adm_menu(); |
| 450 | 450 | $myblock = new \XoopsBlock($bid); |
| 451 | 451 | $db = \XoopsDatabaseFactory::getDatabaseConnection(); |
| 452 | - $sql = 'SELECT module_id FROM ' . $db->prefix('block_module_link') . ' WHERE block_id=' . (int)$bid; |
|
| 452 | + $sql = 'SELECT module_id FROM '.$db->prefix('block_module_link').' WHERE block_id='.(int) $bid; |
|
| 453 | 453 | $result = $db->query($sql); |
| 454 | 454 | $modules = []; |
| 455 | 455 | while (false !== ($row = $db->fetchArray($result))) { |
| 456 | - $modules[] = (int)$row['module_id']; |
|
| 456 | + $modules[] = (int) $row['module_id']; |
|
| 457 | 457 | } |
| 458 | 458 | $isCustom = ('C' === $myblock->getVar('block_type') || 'E' === $myblock->getVar('block_type')); |
| 459 | 459 | $block = [ |
| 460 | 460 | 'title' => $myblock->getVar('title'), |
| 461 | - 'form_title' => constant('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_EDITBLOCK'), |
|
| 461 | + 'form_title' => constant('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_EDITBLOCK'), |
|
| 462 | 462 | // 'name' => $myblock->getVar('name'), |
| 463 | 463 | 'side' => $myblock->getVar('side'), |
| 464 | 464 | 'weight' => $myblock->getVar('weight'), |
@@ -474,12 +474,12 @@ discard block |
||
| 474 | 474 | 'template' => $myblock->getVar('template'), |
| 475 | 475 | 'options' => $myblock->getVar('options'), |
| 476 | 476 | ]; |
| 477 | - echo '<a href="blocksadmin.php">' . constant('CO_' . $moduleDirNameUpper . '_' . 'BADMIN') . '</a> <span style="font-weight:bold;">»»</span> ' . _AM_SYSTEM_BLOCKS_EDITBLOCK . '<br><br>'; |
|
| 478 | - require_once __DIR__ . '/blockform.php'; |
|
| 477 | + echo '<a href="blocksadmin.php">'.constant('CO_'.$moduleDirNameUpper.'_'.'BADMIN').'</a> <span style="font-weight:bold;">»»</span> '._AM_SYSTEM_BLOCKS_EDITBLOCK.'<br><br>'; |
|
| 478 | + require_once __DIR__.'/blockform.php'; |
|
| 479 | 479 | /** @var XoopsThemeForm $form */ |
| 480 | 480 | $form->display(); |
| 481 | 481 | // xoops_cp_footer(); |
| 482 | - require_once __DIR__ . '/admin_footer.php'; |
|
| 482 | + require_once __DIR__.'/admin_footer.php'; |
|
| 483 | 483 | exit(); |
| 484 | 484 | } |
| 485 | 485 | |
@@ -535,7 +535,7 @@ discard block |
||
| 535 | 535 | $xoopsDB->query($sql); |
| 536 | 536 | } else { |
| 537 | 537 | foreach ($bmodule as $bmid) { |
| 538 | - $sql = sprintf('INSERT INTO `%s` (block_id, module_id) VALUES (%u, %d)', $xoopsDB->prefix('block_module_link'), $bid, (int)$bmid); |
|
| 538 | + $sql = sprintf('INSERT INTO `%s` (block_id, module_id) VALUES (%u, %d)', $xoopsDB->prefix('block_module_link'), $bid, (int) $bmid); |
|
| 539 | 539 | $xoopsDB->query($sql); |
| 540 | 540 | } |
| 541 | 541 | } |
@@ -548,14 +548,14 @@ discard block |
||
| 548 | 548 | $xoopsDB->query($sql); |
| 549 | 549 | } |
| 550 | 550 | } |
| 551 | - redirect_header($_SERVER['SCRIPT_NAME'], 1, constant('CO_' . $moduleDirNameUpper . '_' . 'UPDATE_SUCCESS')); |
|
| 551 | + redirect_header($_SERVER['SCRIPT_NAME'], 1, constant('CO_'.$moduleDirNameUpper.'_'.'UPDATE_SUCCESS')); |
|
| 552 | 552 | } |
| 553 | 553 | |
| 554 | 554 | if ('list' === $op) { |
| 555 | 555 | xoops_cp_header(); |
| 556 | 556 | // mpu_adm_menu(); |
| 557 | 557 | listBlocks(); |
| 558 | - require_once __DIR__ . '/admin_footer.php'; |
|
| 558 | + require_once __DIR__.'/admin_footer.php'; |
|
| 559 | 559 | exit(); |
| 560 | 560 | } |
| 561 | 561 | |
@@ -577,7 +577,7 @@ discard block |
||
| 577 | 577 | $xoopsDB->query($sql); |
| 578 | 578 | } else { |
| 579 | 579 | foreach ($bmodule[$i] as $bmid) { |
| 580 | - $sql = sprintf('INSERT INTO `%s` (block_id, module_id) VALUES (%u, %d)', $xoopsDB->prefix('block_module_link'), $bid[$i], (int)$bmid); |
|
| 580 | + $sql = sprintf('INSERT INTO `%s` (block_id, module_id) VALUES (%u, %d)', $xoopsDB->prefix('block_module_link'), $bid[$i], (int) $bmid); |
|
| 581 | 581 | $xoopsDB->query($sql); |
| 582 | 582 | } |
| 583 | 583 | } |
@@ -591,7 +591,7 @@ discard block |
||
| 591 | 591 | } |
| 592 | 592 | } |
| 593 | 593 | } |
| 594 | - redirect_header($_SERVER['SCRIPT_NAME'], 1, constant('CO_' . $moduleDirNameUpper . '_' . 'UPDATE_SUCCESS')); |
|
| 594 | + redirect_header($_SERVER['SCRIPT_NAME'], 1, constant('CO_'.$moduleDirNameUpper.'_'.'UPDATE_SUCCESS')); |
|
| 595 | 595 | } |
| 596 | 596 | if ('clone' === $op) { |
| 597 | 597 | cloneBlock($bid); |
@@ -609,5 +609,5 @@ discard block |
||
| 609 | 609 | isBlockCloned($bid, $bside, $bweight, $bvisible, $bcachetime, $bmodule, $options); |
| 610 | 610 | } |
| 611 | 611 | } else { |
| 612 | - echo constant('CO_' . $moduleDirNameUpper . '_' . 'ERROR403'); |
|
| 612 | + echo constant('CO_'.$moduleDirNameUpper.'_'.'ERROR403'); |
|
| 613 | 613 | } |
@@ -32,7 +32,7 @@ discard block |
||
| 32 | 32 | $helper->loadLanguage('feedback'); |
| 33 | 33 | |
| 34 | 34 | $pathIcon32 = Admin::menuIconPath(''); |
| 35 | -$pathModIcon32 = XOOPS_URL . '/modules/' . $moduleDirName . '/assets/images/icons/32/'; |
|
| 35 | +$pathModIcon32 = XOOPS_URL.'/modules/'.$moduleDirName.'/assets/images/icons/32/'; |
|
| 36 | 36 | if (is_object($helper->getModule()) && false !== $helper->getModule()->getInfo('modicons32')) { |
| 37 | 37 | $pathModIcon32 = $helper->url($helper->getModule()->getInfo('modicons32')); |
| 38 | 38 | } |
@@ -40,41 +40,41 @@ discard block |
||
| 40 | 40 | $adminmenu[] = [ |
| 41 | 41 | 'title' => _MI_CONTACT_MENU_HOME, |
| 42 | 42 | 'desc' => _MI_CONTACT_MENU_HOME_DESC, |
| 43 | - 'icon' => $pathIcon32 . '/home.png', |
|
| 43 | + 'icon' => $pathIcon32.'/home.png', |
|
| 44 | 44 | 'link' => 'admin/index.php', |
| 45 | 45 | ]; |
| 46 | 46 | |
| 47 | 47 | $adminmenu[] = [ |
| 48 | 48 | 'title' => _MI_CONTACT_MENU_CONTACT, |
| 49 | 49 | 'desc' => _MI_CONTACT_MENU_CONTACT_DESC, |
| 50 | - 'icon' => $pathIcon32 . '/content.png', |
|
| 50 | + 'icon' => $pathIcon32.'/content.png', |
|
| 51 | 51 | 'link' => 'admin/main.php', |
| 52 | 52 | ]; |
| 53 | 53 | |
| 54 | 54 | $adminmenu[] = [ |
| 55 | 55 | 'title' => _MI_CONTACT_MENU_LOGS, |
| 56 | 56 | 'desc' => _MI_CONTACT_MENU_LOGS_DESC, |
| 57 | - 'icon' => $pathIcon32 . '/identity.png', |
|
| 57 | + 'icon' => $pathIcon32.'/identity.png', |
|
| 58 | 58 | 'link' => 'admin/log.php', |
| 59 | 59 | ]; |
| 60 | 60 | |
| 61 | 61 | $adminmenu[] = [ |
| 62 | 62 | 'title' => _MI_CONTACT_MENU_TOOLS, |
| 63 | 63 | 'desc' => _MI_CONTACT_MENU_TOOLS_DESC, |
| 64 | - 'icon' => $pathIcon32 . '/delete.png', |
|
| 64 | + 'icon' => $pathIcon32.'/delete.png', |
|
| 65 | 65 | 'link' => 'admin/tools.php', |
| 66 | 66 | ]; |
| 67 | 67 | |
| 68 | 68 | // Blocks Admin |
| 69 | 69 | $adminmenu[] = [ |
| 70 | - 'title' => constant('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS'), |
|
| 70 | + 'title' => constant('CO_'.$moduleDirNameUpper.'_'.'BLOCKS'), |
|
| 71 | 71 | 'link' => 'admin/blocksadmin.php', |
| 72 | - 'icon' => $pathIcon32 . '/block.png', |
|
| 72 | + 'icon' => $pathIcon32.'/block.png', |
|
| 73 | 73 | ]; |
| 74 | 74 | |
| 75 | 75 | $adminmenu[] = [ |
| 76 | 76 | 'title' => _MI_CONTACT_MENU_ABOUT, |
| 77 | 77 | 'desc' => _MI_CONTACT_MENU_ABOUT_DESC, |
| 78 | - 'icon' => $pathIcon32 . '/about.png', |
|
| 78 | + 'icon' => $pathIcon32.'/about.png', |
|
| 79 | 79 | 'link' => 'admin/about.php', |
| 80 | 80 | ]; |
@@ -17,138 +17,138 @@ discard block |
||
| 17 | 17 | $moduleDirName = \basename(\dirname(__DIR__, 2)); |
| 18 | 18 | $moduleDirNameUpper = mb_strtoupper($moduleDirName); |
| 19 | 19 | |
| 20 | -\define('CO_' . $moduleDirNameUpper . '_GDLIBSTATUS', 'GD library support: '); |
|
| 21 | -\define('CO_' . $moduleDirNameUpper . '_GDLIBVERSION', 'GD Library version: '); |
|
| 22 | -\define('CO_' . $moduleDirNameUpper . '_GDOFF', "<span style='font-weight: bold;'>Disabled</span> (No thumbnails available)"); |
|
| 23 | -\define('CO_' . $moduleDirNameUpper . '_GDON', "<span style='font-weight: bold;'>Enabled</span> (Thumbsnails available)"); |
|
| 24 | -\define('CO_' . $moduleDirNameUpper . '_IMAGEINFO', 'Server status'); |
|
| 25 | -\define('CO_' . $moduleDirNameUpper . '_MAXPOSTSIZE', 'Max post size permitted (post_max_size directive in php.ini): '); |
|
| 26 | -\define('CO_' . $moduleDirNameUpper . '_MAXUPLOADSIZE', 'Max upload size permitted (upload_max_filesize directive in php.ini): '); |
|
| 27 | -\define('CO_' . $moduleDirNameUpper . '_MEMORYLIMIT', 'Memory limit (memory_limit directive in php.ini): '); |
|
| 28 | -\define('CO_' . $moduleDirNameUpper . '_METAVERSION', "<span style='font-weight: bold;'>Downloads meta version:</span> "); |
|
| 29 | -\define('CO_' . $moduleDirNameUpper . '_OFF', "<span style='font-weight: bold;'>OFF</span>"); |
|
| 30 | -\define('CO_' . $moduleDirNameUpper . '_ON', "<span style='font-weight: bold;'>ON</span>"); |
|
| 31 | -\define('CO_' . $moduleDirNameUpper . '_SERVERPATH', 'Server path to XOOPS root: '); |
|
| 32 | -\define('CO_' . $moduleDirNameUpper . '_SERVERUPLOADSTATUS', 'Server uploads status: '); |
|
| 33 | -\define('CO_' . $moduleDirNameUpper . '_SPHPINI', "<span style='font-weight: bold;'>Information taken from PHP ini file:</span>"); |
|
| 34 | -\define('CO_' . $moduleDirNameUpper . '_UPLOADPATHDSC', 'Note. Upload path *MUST* contain the full server path of your upload folder.'); |
|
| 35 | - |
|
| 36 | -\define('CO_' . $moduleDirNameUpper . '_PRINT', "<span style='font-weight: bold;'>Print</span>"); |
|
| 37 | -\define('CO_' . $moduleDirNameUpper . '_PDF', "<span style='font-weight: bold;'>Create PDF</span>"); |
|
| 38 | - |
|
| 39 | -\define('CO_' . $moduleDirNameUpper . '_UPGRADEFAILED0', "Update failed - couldn't rename field '%s'"); |
|
| 40 | -\define('CO_' . $moduleDirNameUpper . '_UPGRADEFAILED1', "Update failed - couldn't add new fields"); |
|
| 41 | -\define('CO_' . $moduleDirNameUpper . '_UPGRADEFAILED2', "Update failed - couldn't rename table '%s'"); |
|
| 42 | -\define('CO_' . $moduleDirNameUpper . '_ERROR_COLUMN', 'Could not create column in database : %s'); |
|
| 43 | -\define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_XOOPS', 'This module requires XOOPS %s+ (%s installed)'); |
|
| 44 | -\define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_PHP', 'This module requires PHP version %s+ (%s installed)'); |
|
| 45 | -\define('CO_' . $moduleDirNameUpper . '_ERROR_TAG_REMOVAL', 'Could not remove tags from Tag Module'); |
|
| 46 | - |
|
| 47 | -\define('CO_' . $moduleDirNameUpper . '_FOLDERS_DELETED_OK', 'Upload Folders have been deleted'); |
|
| 20 | +\define('CO_'.$moduleDirNameUpper.'_GDLIBSTATUS', 'GD library support: '); |
|
| 21 | +\define('CO_'.$moduleDirNameUpper.'_GDLIBVERSION', 'GD Library version: '); |
|
| 22 | +\define('CO_'.$moduleDirNameUpper.'_GDOFF', "<span style='font-weight: bold;'>Disabled</span> (No thumbnails available)"); |
|
| 23 | +\define('CO_'.$moduleDirNameUpper.'_GDON', "<span style='font-weight: bold;'>Enabled</span> (Thumbsnails available)"); |
|
| 24 | +\define('CO_'.$moduleDirNameUpper.'_IMAGEINFO', 'Server status'); |
|
| 25 | +\define('CO_'.$moduleDirNameUpper.'_MAXPOSTSIZE', 'Max post size permitted (post_max_size directive in php.ini): '); |
|
| 26 | +\define('CO_'.$moduleDirNameUpper.'_MAXUPLOADSIZE', 'Max upload size permitted (upload_max_filesize directive in php.ini): '); |
|
| 27 | +\define('CO_'.$moduleDirNameUpper.'_MEMORYLIMIT', 'Memory limit (memory_limit directive in php.ini): '); |
|
| 28 | +\define('CO_'.$moduleDirNameUpper.'_METAVERSION', "<span style='font-weight: bold;'>Downloads meta version:</span> "); |
|
| 29 | +\define('CO_'.$moduleDirNameUpper.'_OFF', "<span style='font-weight: bold;'>OFF</span>"); |
|
| 30 | +\define('CO_'.$moduleDirNameUpper.'_ON', "<span style='font-weight: bold;'>ON</span>"); |
|
| 31 | +\define('CO_'.$moduleDirNameUpper.'_SERVERPATH', 'Server path to XOOPS root: '); |
|
| 32 | +\define('CO_'.$moduleDirNameUpper.'_SERVERUPLOADSTATUS', 'Server uploads status: '); |
|
| 33 | +\define('CO_'.$moduleDirNameUpper.'_SPHPINI', "<span style='font-weight: bold;'>Information taken from PHP ini file:</span>"); |
|
| 34 | +\define('CO_'.$moduleDirNameUpper.'_UPLOADPATHDSC', 'Note. Upload path *MUST* contain the full server path of your upload folder.'); |
|
| 35 | + |
|
| 36 | +\define('CO_'.$moduleDirNameUpper.'_PRINT', "<span style='font-weight: bold;'>Print</span>"); |
|
| 37 | +\define('CO_'.$moduleDirNameUpper.'_PDF', "<span style='font-weight: bold;'>Create PDF</span>"); |
|
| 38 | + |
|
| 39 | +\define('CO_'.$moduleDirNameUpper.'_UPGRADEFAILED0', "Update failed - couldn't rename field '%s'"); |
|
| 40 | +\define('CO_'.$moduleDirNameUpper.'_UPGRADEFAILED1', "Update failed - couldn't add new fields"); |
|
| 41 | +\define('CO_'.$moduleDirNameUpper.'_UPGRADEFAILED2', "Update failed - couldn't rename table '%s'"); |
|
| 42 | +\define('CO_'.$moduleDirNameUpper.'_ERROR_COLUMN', 'Could not create column in database : %s'); |
|
| 43 | +\define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_XOOPS', 'This module requires XOOPS %s+ (%s installed)'); |
|
| 44 | +\define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_PHP', 'This module requires PHP version %s+ (%s installed)'); |
|
| 45 | +\define('CO_'.$moduleDirNameUpper.'_ERROR_TAG_REMOVAL', 'Could not remove tags from Tag Module'); |
|
| 46 | + |
|
| 47 | +\define('CO_'.$moduleDirNameUpper.'_FOLDERS_DELETED_OK', 'Upload Folders have been deleted'); |
|
| 48 | 48 | |
| 49 | 49 | // Error Msgs |
| 50 | -\define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_DEL_PATH', 'Could not delete %s directory'); |
|
| 51 | -\define('CO_' . $moduleDirNameUpper . '_ERROR_BAD_REMOVE', 'Could not delete %s'); |
|
| 52 | -\define('CO_' . $moduleDirNameUpper . '_ERROR_NO_PLUGIN', 'Could not load plugin'); |
|
| 50 | +\define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_DEL_PATH', 'Could not delete %s directory'); |
|
| 51 | +\define('CO_'.$moduleDirNameUpper.'_ERROR_BAD_REMOVE', 'Could not delete %s'); |
|
| 52 | +\define('CO_'.$moduleDirNameUpper.'_ERROR_NO_PLUGIN', 'Could not load plugin'); |
|
| 53 | 53 | |
| 54 | 54 | //Help |
| 55 | -\define('CO_' . $moduleDirNameUpper . '_DIRNAME', basename(dirname(__DIR__, 2))); |
|
| 56 | -\define('CO_' . $moduleDirNameUpper . '_HELP_HEADER', __DIR__ . '/help/helpheader.tpl'); |
|
| 57 | -\define('CO_' . $moduleDirNameUpper . '_BACK_2_ADMIN', 'Back to Administration of '); |
|
| 58 | -\define('CO_' . $moduleDirNameUpper . '_OVERVIEW', 'Overview'); |
|
| 55 | +\define('CO_'.$moduleDirNameUpper.'_DIRNAME', basename(dirname(__DIR__, 2))); |
|
| 56 | +\define('CO_'.$moduleDirNameUpper.'_HELP_HEADER', __DIR__.'/help/helpheader.tpl'); |
|
| 57 | +\define('CO_'.$moduleDirNameUpper.'_BACK_2_ADMIN', 'Back to Administration of '); |
|
| 58 | +\define('CO_'.$moduleDirNameUpper.'_OVERVIEW', 'Overview'); |
|
| 59 | 59 | |
| 60 | 60 | //\define('CO_' . $moduleDirNameUpper . '_HELP_DIR', __DIR__); |
| 61 | 61 | |
| 62 | 62 | //help multi-page |
| 63 | -\define('CO_' . $moduleDirNameUpper . '_DISCLAIMER', 'Disclaimer'); |
|
| 64 | -\define('CO_' . $moduleDirNameUpper . '_LICENSE', 'License'); |
|
| 65 | -\define('CO_' . $moduleDirNameUpper . '_SUPPORT', 'Support'); |
|
| 63 | +\define('CO_'.$moduleDirNameUpper.'_DISCLAIMER', 'Disclaimer'); |
|
| 64 | +\define('CO_'.$moduleDirNameUpper.'_LICENSE', 'License'); |
|
| 65 | +\define('CO_'.$moduleDirNameUpper.'_SUPPORT', 'Support'); |
|
| 66 | 66 | |
| 67 | 67 | //Sample Data |
| 68 | -\define('CO_' . $moduleDirNameUpper . '_' . 'LOAD_SAMPLEDATA', 'Import Sample Data (will delete ALL current data)'); |
|
| 69 | -\define('CO_' . $moduleDirNameUpper . '_' . 'LOAD_SAMPLEDATA_CONFIRM', 'Are you sure to Import Sample Data? (It will delete ALL current data)'); |
|
| 70 | -\define('CO_' . $moduleDirNameUpper . '_' . 'LOAD_SAMPLEDATA_SUCCESS', 'Sample Date imported successfully'); |
|
| 71 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SAVE_SAMPLEDATA', 'Export Tables to YAML'); |
|
| 72 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SAVE_SAMPLEDATA_SUCCESS', 'Export Tables to YAML successfully'); |
|
| 73 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CLEAR_SAMPLEDATA', 'Clear Sample Data'); |
|
| 74 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CLEAR_SAMPLEDATA_OK', 'The Sample Data has been cleared'); |
|
| 75 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CLEAR_SAMPLEDATA_CONFIRM', 'Are you sure to Clear Sample Data? (It will delete ALL current data)'); |
|
| 76 | -\define('CO_' . $moduleDirNameUpper . '_' . 'EXPORT_SCHEMA', 'Export DB Schema to YAML'); |
|
| 77 | -\define('CO_' . $moduleDirNameUpper . '_' . 'EXPORT_SCHEMA_SUCCESS', 'Export DB Schema to YAML was a success'); |
|
| 78 | -\define('CO_' . $moduleDirNameUpper . '_' . 'EXPORT_SCHEMA_ERROR', 'ERROR: Export of DB Schema to YAML failed'); |
|
| 79 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SHOW_SAMPLE_BUTTON', 'Show Sample Button?'); |
|
| 80 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SHOW_SAMPLE_BUTTON_DESC', 'If yes, the "Add Sample Data" button will be visible to the Admin. It is Yes as a default for first installation.'); |
|
| 81 | -\define('CO_' . $moduleDirNameUpper . '_' . 'HIDE_SAMPLEDATA_BUTTONS', 'Hide the Import buttons)'); |
|
| 82 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SHOW_SAMPLEDATA_BUTTONS', 'Show the Import buttons)'); |
|
| 83 | - |
|
| 84 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CONFIRM', 'Confirm'); |
|
| 68 | +\define('CO_'.$moduleDirNameUpper.'_'.'LOAD_SAMPLEDATA', 'Import Sample Data (will delete ALL current data)'); |
|
| 69 | +\define('CO_'.$moduleDirNameUpper.'_'.'LOAD_SAMPLEDATA_CONFIRM', 'Are you sure to Import Sample Data? (It will delete ALL current data)'); |
|
| 70 | +\define('CO_'.$moduleDirNameUpper.'_'.'LOAD_SAMPLEDATA_SUCCESS', 'Sample Date imported successfully'); |
|
| 71 | +\define('CO_'.$moduleDirNameUpper.'_'.'SAVE_SAMPLEDATA', 'Export Tables to YAML'); |
|
| 72 | +\define('CO_'.$moduleDirNameUpper.'_'.'SAVE_SAMPLEDATA_SUCCESS', 'Export Tables to YAML successfully'); |
|
| 73 | +\define('CO_'.$moduleDirNameUpper.'_'.'CLEAR_SAMPLEDATA', 'Clear Sample Data'); |
|
| 74 | +\define('CO_'.$moduleDirNameUpper.'_'.'CLEAR_SAMPLEDATA_OK', 'The Sample Data has been cleared'); |
|
| 75 | +\define('CO_'.$moduleDirNameUpper.'_'.'CLEAR_SAMPLEDATA_CONFIRM', 'Are you sure to Clear Sample Data? (It will delete ALL current data)'); |
|
| 76 | +\define('CO_'.$moduleDirNameUpper.'_'.'EXPORT_SCHEMA', 'Export DB Schema to YAML'); |
|
| 77 | +\define('CO_'.$moduleDirNameUpper.'_'.'EXPORT_SCHEMA_SUCCESS', 'Export DB Schema to YAML was a success'); |
|
| 78 | +\define('CO_'.$moduleDirNameUpper.'_'.'EXPORT_SCHEMA_ERROR', 'ERROR: Export of DB Schema to YAML failed'); |
|
| 79 | +\define('CO_'.$moduleDirNameUpper.'_'.'SHOW_SAMPLE_BUTTON', 'Show Sample Button?'); |
|
| 80 | +\define('CO_'.$moduleDirNameUpper.'_'.'SHOW_SAMPLE_BUTTON_DESC', 'If yes, the "Add Sample Data" button will be visible to the Admin. It is Yes as a default for first installation.'); |
|
| 81 | +\define('CO_'.$moduleDirNameUpper.'_'.'HIDE_SAMPLEDATA_BUTTONS', 'Hide the Import buttons)'); |
|
| 82 | +\define('CO_'.$moduleDirNameUpper.'_'.'SHOW_SAMPLEDATA_BUTTONS', 'Show the Import buttons)'); |
|
| 83 | + |
|
| 84 | +\define('CO_'.$moduleDirNameUpper.'_'.'CONFIRM', 'Confirm'); |
|
| 85 | 85 | |
| 86 | 86 | //letter choice |
| 87 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BROWSETOTOPIC', "<span style='font-weight: bold;'>Browse items alphabetically</span>"); |
|
| 88 | -\define('CO_' . $moduleDirNameUpper . '_' . 'OTHER', 'Other'); |
|
| 89 | -\define('CO_' . $moduleDirNameUpper . '_' . 'ALL', 'All'); |
|
| 87 | +\define('CO_'.$moduleDirNameUpper.'_'.'BROWSETOTOPIC', "<span style='font-weight: bold;'>Browse items alphabetically</span>"); |
|
| 88 | +\define('CO_'.$moduleDirNameUpper.'_'.'OTHER', 'Other'); |
|
| 89 | +\define('CO_'.$moduleDirNameUpper.'_'.'ALL', 'All'); |
|
| 90 | 90 | |
| 91 | 91 | // block defines |
| 92 | -\define('CO_' . $moduleDirNameUpper . '_' . 'ACCESSRIGHTS', 'Access Rights'); |
|
| 93 | -\define('CO_' . $moduleDirNameUpper . '_' . 'ACTION', 'Action'); |
|
| 94 | -\define('CO_' . $moduleDirNameUpper . '_' . 'ACTIVERIGHTS', 'Active Rights'); |
|
| 95 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BADMIN', 'Block Administration'); |
|
| 96 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLKDESC', 'Description'); |
|
| 97 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CBCENTER', 'Center Middle'); |
|
| 98 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CBLEFT', 'Center Left'); |
|
| 99 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CBRIGHT', 'Center Right'); |
|
| 100 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SBLEFT', 'Left'); |
|
| 101 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SBRIGHT', 'Right'); |
|
| 102 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SIDE', 'Alignment'); |
|
| 103 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TITLE', 'Title'); |
|
| 104 | -\define('CO_' . $moduleDirNameUpper . '_' . 'VISIBLE', 'Visible'); |
|
| 105 | -\define('CO_' . $moduleDirNameUpper . '_' . 'VISIBLEIN', 'Visible In'); |
|
| 106 | -\define('CO_' . $moduleDirNameUpper . '_' . 'WEIGHT', 'Weight'); |
|
| 107 | - |
|
| 108 | -\define('CO_' . $moduleDirNameUpper . '_' . 'PERMISSIONS', 'Permissions'); |
|
| 109 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS', 'Blocks Admin'); |
|
| 110 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_DESC', 'Blocks/Group Admin'); |
|
| 111 | - |
|
| 112 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_MANAGMENT', 'Manage'); |
|
| 113 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_ADDBLOCK', 'Add a new block'); |
|
| 114 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_EDITBLOCK', 'Edit a block'); |
|
| 115 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_CLONEBLOCK', 'Clone a block'); |
|
| 92 | +\define('CO_'.$moduleDirNameUpper.'_'.'ACCESSRIGHTS', 'Access Rights'); |
|
| 93 | +\define('CO_'.$moduleDirNameUpper.'_'.'ACTION', 'Action'); |
|
| 94 | +\define('CO_'.$moduleDirNameUpper.'_'.'ACTIVERIGHTS', 'Active Rights'); |
|
| 95 | +\define('CO_'.$moduleDirNameUpper.'_'.'BADMIN', 'Block Administration'); |
|
| 96 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLKDESC', 'Description'); |
|
| 97 | +\define('CO_'.$moduleDirNameUpper.'_'.'CBCENTER', 'Center Middle'); |
|
| 98 | +\define('CO_'.$moduleDirNameUpper.'_'.'CBLEFT', 'Center Left'); |
|
| 99 | +\define('CO_'.$moduleDirNameUpper.'_'.'CBRIGHT', 'Center Right'); |
|
| 100 | +\define('CO_'.$moduleDirNameUpper.'_'.'SBLEFT', 'Left'); |
|
| 101 | +\define('CO_'.$moduleDirNameUpper.'_'.'SBRIGHT', 'Right'); |
|
| 102 | +\define('CO_'.$moduleDirNameUpper.'_'.'SIDE', 'Alignment'); |
|
| 103 | +\define('CO_'.$moduleDirNameUpper.'_'.'TITLE', 'Title'); |
|
| 104 | +\define('CO_'.$moduleDirNameUpper.'_'.'VISIBLE', 'Visible'); |
|
| 105 | +\define('CO_'.$moduleDirNameUpper.'_'.'VISIBLEIN', 'Visible In'); |
|
| 106 | +\define('CO_'.$moduleDirNameUpper.'_'.'WEIGHT', 'Weight'); |
|
| 107 | + |
|
| 108 | +\define('CO_'.$moduleDirNameUpper.'_'.'PERMISSIONS', 'Permissions'); |
|
| 109 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLOCKS', 'Blocks Admin'); |
|
| 110 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_DESC', 'Blocks/Group Admin'); |
|
| 111 | + |
|
| 112 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_MANAGMENT', 'Manage'); |
|
| 113 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_ADDBLOCK', 'Add a new block'); |
|
| 114 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_EDITBLOCK', 'Edit a block'); |
|
| 115 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_CLONEBLOCK', 'Clone a block'); |
|
| 116 | 116 | |
| 117 | 117 | //myblocksadmin |
| 118 | -\define('CO_' . $moduleDirNameUpper . '_' . 'AGDS', 'Admin Groups'); |
|
| 119 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BCACHETIME', 'Cache Time'); |
|
| 120 | -\define('CO_' . $moduleDirNameUpper . '_' . 'BLOCKS_ADMIN', 'Blocks Admin'); |
|
| 121 | -\define('CO_' . $moduleDirNameUpper . '_' . 'UPDATE_SUCCESS', 'Update successful'); |
|
| 118 | +\define('CO_'.$moduleDirNameUpper.'_'.'AGDS', 'Admin Groups'); |
|
| 119 | +\define('CO_'.$moduleDirNameUpper.'_'.'BCACHETIME', 'Cache Time'); |
|
| 120 | +\define('CO_'.$moduleDirNameUpper.'_'.'BLOCKS_ADMIN', 'Blocks Admin'); |
|
| 121 | +\define('CO_'.$moduleDirNameUpper.'_'.'UPDATE_SUCCESS', 'Update successful'); |
|
| 122 | 122 | |
| 123 | 123 | //Template Admin |
| 124 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TPLSETS', 'Template Management'); |
|
| 125 | -\define('CO_' . $moduleDirNameUpper . '_' . 'GENERATE', 'Generate'); |
|
| 126 | -\define('CO_' . $moduleDirNameUpper . '_' . 'FILENAME', 'File Name'); |
|
| 124 | +\define('CO_'.$moduleDirNameUpper.'_'.'TPLSETS', 'Template Management'); |
|
| 125 | +\define('CO_'.$moduleDirNameUpper.'_'.'GENERATE', 'Generate'); |
|
| 126 | +\define('CO_'.$moduleDirNameUpper.'_'.'FILENAME', 'File Name'); |
|
| 127 | 127 | |
| 128 | 128 | //Menu |
| 129 | -\define('CO_' . $moduleDirNameUpper . '_' . 'ADMENU_MIGRATE', 'Migrate'); |
|
| 130 | -\define('CO_' . $moduleDirNameUpper . '_' . 'FOLDER_YES', 'Folder "%s" exist'); |
|
| 131 | -\define('CO_' . $moduleDirNameUpper . '_' . 'FOLDER_NO', 'Folder "%s" does not exist. Create the specified folder with CHMOD 777.'); |
|
| 132 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SHOW_DEV_TOOLS', 'Show Development Tools Button?'); |
|
| 133 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SHOW_DEV_TOOLS_DESC', 'If yes, the "Migrate" Tab and other Development tools will be visible to the Admin.'); |
|
| 134 | -\define('CO_' . $moduleDirNameUpper . '_' . 'ADMENU_FEEDBACK', 'Feedback'); |
|
| 135 | -\define('CO_' . $moduleDirNameUpper . '_' . 'MIGRATE_OK', 'Database migrated to current schema.'); |
|
| 136 | -\define('CO_' . $moduleDirNameUpper . '_' . 'MIGRATE_WARNING', 'Warning! This is intended for developers only. Confirm write schema file from current database.'); |
|
| 137 | -\define('CO_' . $moduleDirNameUpper . '_' . 'MIGRATE_SCHEMA_OK', 'Current schema file written'); |
|
| 129 | +\define('CO_'.$moduleDirNameUpper.'_'.'ADMENU_MIGRATE', 'Migrate'); |
|
| 130 | +\define('CO_'.$moduleDirNameUpper.'_'.'FOLDER_YES', 'Folder "%s" exist'); |
|
| 131 | +\define('CO_'.$moduleDirNameUpper.'_'.'FOLDER_NO', 'Folder "%s" does not exist. Create the specified folder with CHMOD 777.'); |
|
| 132 | +\define('CO_'.$moduleDirNameUpper.'_'.'SHOW_DEV_TOOLS', 'Show Development Tools Button?'); |
|
| 133 | +\define('CO_'.$moduleDirNameUpper.'_'.'SHOW_DEV_TOOLS_DESC', 'If yes, the "Migrate" Tab and other Development tools will be visible to the Admin.'); |
|
| 134 | +\define('CO_'.$moduleDirNameUpper.'_'.'ADMENU_FEEDBACK', 'Feedback'); |
|
| 135 | +\define('CO_'.$moduleDirNameUpper.'_'.'MIGRATE_OK', 'Database migrated to current schema.'); |
|
| 136 | +\define('CO_'.$moduleDirNameUpper.'_'.'MIGRATE_WARNING', 'Warning! This is intended for developers only. Confirm write schema file from current database.'); |
|
| 137 | +\define('CO_'.$moduleDirNameUpper.'_'.'MIGRATE_SCHEMA_OK', 'Current schema file written'); |
|
| 138 | 138 | |
| 139 | 139 | //Latest Version Check |
| 140 | -\define('CO_' . $moduleDirNameUpper . '_' . 'NEW_VERSION', 'New Version: '); |
|
| 140 | +\define('CO_'.$moduleDirNameUpper.'_'.'NEW_VERSION', 'New Version: '); |
|
| 141 | 141 | |
| 142 | 142 | //DirectoryChecker |
| 143 | -\define('CO_' . $moduleDirNameUpper . '_' . 'AVAILABLE', "<span style='color: green;'>Available</span>"); |
|
| 144 | -\define('CO_' . $moduleDirNameUpper . '_' . 'NOTAVAILABLE', "<span style='color: red;'>Not available</span>"); |
|
| 145 | -\define('CO_' . $moduleDirNameUpper . '_' . 'NOTWRITABLE', "<span style='color: red;'>Should have permission ( %d ), but it has ( %d )</span>"); |
|
| 146 | -\define('CO_' . $moduleDirNameUpper . '_' . 'CREATETHEDIR', 'Create it'); |
|
| 147 | -\define('CO_' . $moduleDirNameUpper . '_' . 'SETMPERM', 'Set the permission'); |
|
| 148 | -\define('CO_' . $moduleDirNameUpper . '_' . 'DIRCREATED', 'The directory has been created'); |
|
| 149 | -\define('CO_' . $moduleDirNameUpper . '_' . 'DIRNOTCREATED', 'The directory cannot be created'); |
|
| 150 | -\define('CO_' . $moduleDirNameUpper . '_' . 'PERMSET', 'The permission has been set'); |
|
| 151 | -\define('CO_' . $moduleDirNameUpper . '_' . 'PERMNOTSET', 'The permission cannot be set'); |
|
| 143 | +\define('CO_'.$moduleDirNameUpper.'_'.'AVAILABLE', "<span style='color: green;'>Available</span>"); |
|
| 144 | +\define('CO_'.$moduleDirNameUpper.'_'.'NOTAVAILABLE', "<span style='color: red;'>Not available</span>"); |
|
| 145 | +\define('CO_'.$moduleDirNameUpper.'_'.'NOTWRITABLE', "<span style='color: red;'>Should have permission ( %d ), but it has ( %d )</span>"); |
|
| 146 | +\define('CO_'.$moduleDirNameUpper.'_'.'CREATETHEDIR', 'Create it'); |
|
| 147 | +\define('CO_'.$moduleDirNameUpper.'_'.'SETMPERM', 'Set the permission'); |
|
| 148 | +\define('CO_'.$moduleDirNameUpper.'_'.'DIRCREATED', 'The directory has been created'); |
|
| 149 | +\define('CO_'.$moduleDirNameUpper.'_'.'DIRNOTCREATED', 'The directory cannot be created'); |
|
| 150 | +\define('CO_'.$moduleDirNameUpper.'_'.'PERMSET', 'The permission has been set'); |
|
| 151 | +\define('CO_'.$moduleDirNameUpper.'_'.'PERMNOTSET', 'The permission cannot be set'); |
|
| 152 | 152 | |
| 153 | 153 | //FileChecker |
| 154 | 154 | //\define('CO_' . $moduleDirNameUpper . '_' . 'AVAILABLE', "<span style='color: green;'>Available</span>"); |
@@ -158,31 +158,31 @@ discard block |
||
| 158 | 158 | //\define('CO_' . $moduleDirNameUpper . '_' . 'CREATETHEFILE', 'Create it'); |
| 159 | 159 | //\define('CO_' . $moduleDirNameUpper . '_' . 'SETMPERM', 'Set the permission'); |
| 160 | 160 | |
| 161 | -\define('CO_' . $moduleDirNameUpper . '_' . 'FILECOPIED', 'The file has been copied'); |
|
| 162 | -\define('CO_' . $moduleDirNameUpper . '_' . 'FILENOTCOPIED', 'The file cannot be copied'); |
|
| 161 | +\define('CO_'.$moduleDirNameUpper.'_'.'FILECOPIED', 'The file has been copied'); |
|
| 162 | +\define('CO_'.$moduleDirNameUpper.'_'.'FILENOTCOPIED', 'The file cannot be copied'); |
|
| 163 | 163 | |
| 164 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TRUNCATE_LENGTH', 'Number of Characters to truncate to the long text field'); |
|
| 165 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TRUNCATE_LENGTH_DESC', 'Set the maximum number of characters to truncate the long text fields'); |
|
| 164 | +\define('CO_'.$moduleDirNameUpper.'_'.'TRUNCATE_LENGTH', 'Number of Characters to truncate to the long text field'); |
|
| 165 | +\define('CO_'.$moduleDirNameUpper.'_'.'TRUNCATE_LENGTH_DESC', 'Set the maximum number of characters to truncate the long text fields'); |
|
| 166 | 166 | |
| 167 | 167 | //image config |
| 168 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_WIDTH', 'Image Display Width'); |
|
| 169 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_WIDTH_DSC', 'Display width for image'); |
|
| 170 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_HEIGHT', 'Image Display Height'); |
|
| 171 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_HEIGHT_DSC', 'Display height for image'); |
|
| 172 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_CONFIG', '<span style="color: #FF0000; font-size: Small; font-weight: bold;">--- EXTERNAL Image configuration ---</span> '); |
|
| 173 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_CONFIG_DSC', ''); |
|
| 174 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_UPLOAD_PATH', 'Image Upload path'); |
|
| 175 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_UPLOAD_PATH_DSC', 'Path for uploading images'); |
|
| 168 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_WIDTH', 'Image Display Width'); |
|
| 169 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_WIDTH_DSC', 'Display width for image'); |
|
| 170 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_HEIGHT', 'Image Display Height'); |
|
| 171 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_HEIGHT_DSC', 'Display height for image'); |
|
| 172 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_CONFIG', '<span style="color: #FF0000; font-size: Small; font-weight: bold;">--- EXTERNAL Image configuration ---</span> '); |
|
| 173 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_CONFIG_DSC', ''); |
|
| 174 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_UPLOAD_PATH', 'Image Upload path'); |
|
| 175 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_UPLOAD_PATH_DSC', 'Path for uploading images'); |
|
| 176 | 176 | |
| 177 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_FILE_SIZE', 'Image File Size (in Bytes)'); |
|
| 178 | -\define('CO_' . $moduleDirNameUpper . '_' . 'IMAGE_FILE_SIZE_DSC','The maximum file size of the image file (in Bytes)'); |
|
| 177 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_FILE_SIZE', 'Image File Size (in Bytes)'); |
|
| 178 | +\define('CO_'.$moduleDirNameUpper.'_'.'IMAGE_FILE_SIZE_DSC', 'The maximum file size of the image file (in Bytes)'); |
|
| 179 | 179 | |
| 180 | 180 | |
| 181 | 181 | //Module Stats |
| 182 | -\define('CO_' . $moduleDirNameUpper . '_' . 'STATS_SUMMARY', 'Module Statistics'); |
|
| 183 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TOTAL_CATEGORIES', 'Categories:'); |
|
| 184 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TOTAL_ITEMS', 'Items'); |
|
| 185 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TOTAL_OFFLINE', 'Offline'); |
|
| 186 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TOTAL_PUBLISHED', 'Published'); |
|
| 187 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TOTAL_REJECTED', 'Rejected'); |
|
| 188 | -\define('CO_' . $moduleDirNameUpper . '_' . 'TOTAL_SUBMITTED', 'Submitted'); |
|
| 182 | +\define('CO_'.$moduleDirNameUpper.'_'.'STATS_SUMMARY', 'Module Statistics'); |
|
| 183 | +\define('CO_'.$moduleDirNameUpper.'_'.'TOTAL_CATEGORIES', 'Categories:'); |
|
| 184 | +\define('CO_'.$moduleDirNameUpper.'_'.'TOTAL_ITEMS', 'Items'); |
|
| 185 | +\define('CO_'.$moduleDirNameUpper.'_'.'TOTAL_OFFLINE', 'Offline'); |
|
| 186 | +\define('CO_'.$moduleDirNameUpper.'_'.'TOTAL_PUBLISHED', 'Published'); |
|
| 187 | +\define('CO_'.$moduleDirNameUpper.'_'.'TOTAL_REJECTED', 'Rejected'); |
|
| 188 | +\define('CO_'.$moduleDirNameUpper.'_'.'TOTAL_SUBMITTED', 'Submitted'); |
|
@@ -21,33 +21,33 @@ discard block |
||
| 21 | 21 | $moduleDirNameUpper = mb_strtoupper($moduleDirName); |
| 22 | 22 | xoops_loadLanguage('common', $moduleDirName); |
| 23 | 23 | |
| 24 | -return (object)[ |
|
| 25 | - 'name' => $moduleDirNameUpper . ' ModuleConfigurator', |
|
| 24 | +return (object) [ |
|
| 25 | + 'name' => $moduleDirNameUpper.' ModuleConfigurator', |
|
| 26 | 26 | 'paths' => [ |
| 27 | 27 | 'dirname' => $moduleDirName, |
| 28 | - 'admin' => XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/admin', |
|
| 29 | - 'modPath' => XOOPS_ROOT_PATH . '/modules/' . $moduleDirName, |
|
| 30 | - 'modUrl' => XOOPS_URL . '/modules/' . $moduleDirName, |
|
| 31 | - 'uploadPath' => XOOPS_UPLOAD_PATH . '/' . $moduleDirName, |
|
| 32 | - 'uploadUrl' => XOOPS_UPLOAD_URL . '/' . $moduleDirName, |
|
| 28 | + 'admin' => XOOPS_ROOT_PATH.'/modules/'.$moduleDirName.'/admin', |
|
| 29 | + 'modPath' => XOOPS_ROOT_PATH.'/modules/'.$moduleDirName, |
|
| 30 | + 'modUrl' => XOOPS_URL.'/modules/'.$moduleDirName, |
|
| 31 | + 'uploadPath' => XOOPS_UPLOAD_PATH.'/'.$moduleDirName, |
|
| 32 | + 'uploadUrl' => XOOPS_UPLOAD_URL.'/'.$moduleDirName, |
|
| 33 | 33 | ], |
| 34 | 34 | 'uploadFolders' => [ |
| 35 | - XOOPS_UPLOAD_PATH . '/' . $moduleDirName, |
|
| 36 | - XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/midsize', |
|
| 37 | - XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/thumbs', |
|
| 35 | + XOOPS_UPLOAD_PATH.'/'.$moduleDirName, |
|
| 36 | + XOOPS_UPLOAD_PATH.'/'.$moduleDirName.'/midsize', |
|
| 37 | + XOOPS_UPLOAD_PATH.'/'.$moduleDirName.'/thumbs', |
|
| 38 | 38 | //XOOPS_UPLOAD_PATH . '/flags' |
| 39 | 39 | ], |
| 40 | 40 | 'copyBlankFiles' => [ |
| 41 | - XOOPS_UPLOAD_PATH . '/' . $moduleDirName, |
|
| 42 | - XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/midsize', |
|
| 43 | - XOOPS_UPLOAD_PATH . '/' . $moduleDirName . '/thumbs', |
|
| 41 | + XOOPS_UPLOAD_PATH.'/'.$moduleDirName, |
|
| 42 | + XOOPS_UPLOAD_PATH.'/'.$moduleDirName.'/midsize', |
|
| 43 | + XOOPS_UPLOAD_PATH.'/'.$moduleDirName.'/thumbs', |
|
| 44 | 44 | //XOOPS_UPLOAD_PATH . '/flags' |
| 45 | 45 | ], |
| 46 | 46 | |
| 47 | 47 | 'copyTestFolders' => [ |
| 48 | 48 | [ |
| 49 | - XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/testdata/uploads', |
|
| 50 | - XOOPS_UPLOAD_PATH . '/' . $moduleDirName, |
|
| 49 | + XOOPS_ROOT_PATH.'/modules/'.$moduleDirName.'/testdata/uploads', |
|
| 50 | + XOOPS_UPLOAD_PATH.'/'.$moduleDirName, |
|
| 51 | 51 | ], |
| 52 | 52 | // [ |
| 53 | 53 | // XOOPS_ROOT_PATH . '/modules/' . $moduleDirName . '/testdata/thumbs', |
@@ -84,6 +84,6 @@ discard block |
||
| 84 | 84 | // 'totalsubmitted' => $helper->getHandler('Item')->getItemsCount(-1, [Constants::PUBLISHER_STATUS_SUBMITTED]), |
| 85 | 85 | ], |
| 86 | 86 | 'modCopyright' => "<a href='https://xoops.org' title='XOOPS Project' target='_blank'> |
| 87 | - <img src='" . Admin::iconUrl('xoopsmicrobutton.gif') . "' alt='XOOPS Project'></a>", |
|
| 87 | + <img src='" . Admin::iconUrl('xoopsmicrobutton.gif')."' alt='XOOPS Project'></a>", |
|
| 88 | 88 | ]; |
| 89 | 89 | |
@@ -35,7 +35,7 @@ discard block |
||
| 35 | 35 | if (!\mkdir($folder) && !\is_dir($folder)) { |
| 36 | 36 | throw new RuntimeException(\sprintf('Unable to create the %s directory', $folder)); |
| 37 | 37 | } else { |
| 38 | - file_put_contents($folder . '/index.html', '<script>history.go(-1);</script>'); |
|
| 38 | + file_put_contents($folder.'/index.html', '<script>history.go(-1);</script>'); |
|
| 39 | 39 | } |
| 40 | 40 | } |
| 41 | 41 | } catch (\Exception $e) { |
@@ -73,10 +73,10 @@ discard block |
||
| 73 | 73 | // @mkdir($dst); |
| 74 | 74 | while (false !== ($file = \readdir($dir))) { |
| 75 | 75 | if (($file !== '.') && ($file !== '..')) { |
| 76 | - if (\is_dir($src . '/' . $file)) { |
|
| 77 | - self::recurseCopy($src . '/' . $file, $dst . '/' . $file); |
|
| 76 | + if (\is_dir($src.'/'.$file)) { |
|
| 77 | + self::recurseCopy($src.'/'.$file, $dst.'/'.$file); |
|
| 78 | 78 | } else { |
| 79 | - \copy($src . '/' . $file, $dst . '/' . $file); |
|
| 79 | + \copy($src.'/'.$file, $dst.'/'.$file); |
|
| 80 | 80 | } |
| 81 | 81 | } |
| 82 | 82 | } |
@@ -144,34 +144,34 @@ discard block |
||
| 144 | 144 | $info = ''; |
| 145 | 145 | $subjectPrefix = ''; |
| 146 | 146 | if ($GLOBALS['xoopsModuleConfig']['form_dept'] && $GLOBALS['xoopsModuleConfig']['subject_prefix'] && $GLOBALS['xoopsModuleConfig']['contact_dept']) { |
| 147 | - $subjectPrefix = '[' . $GLOBALS['xoopsModuleConfig']['prefix_text'] . ' ' . $contact['contact_department'] . ']: '; |
|
| 148 | - $info .= _MD_CONTACT_DEPARTMENT . ': ' . $contact['contact_department'] . "\n"; |
|
| 147 | + $subjectPrefix = '['.$GLOBALS['xoopsModuleConfig']['prefix_text'].' '.$contact['contact_department'].']: '; |
|
| 148 | + $info .= _MD_CONTACT_DEPARTMENT.': '.$contact['contact_department']."\n"; |
|
| 149 | 149 | } |
| 150 | - $xoopsMailer->setSubject($subjectPrefix . \html_entity_decode($contact['contact_subject'], \ENT_QUOTES, 'UTF-8')); |
|
| 150 | + $xoopsMailer->setSubject($subjectPrefix.\html_entity_decode($contact['contact_subject'], \ENT_QUOTES, 'UTF-8')); |
|
| 151 | 151 | |
| 152 | 152 | if ($contact['contact_url']) { |
| 153 | - $info .= _MD_CONTACT_URL . ': ' . $contact['contact_url'] . "\n"; |
|
| 153 | + $info .= _MD_CONTACT_URL.': '.$contact['contact_url']."\n"; |
|
| 154 | 154 | } |
| 155 | 155 | if ($contact['contact_icq']) { |
| 156 | - $info .= _MD_CONTACT_ICQ . ': ' . $contact['contact_icq'] . "\n"; |
|
| 156 | + $info .= _MD_CONTACT_ICQ.': '.$contact['contact_icq']."\n"; |
|
| 157 | 157 | } |
| 158 | 158 | if ($contact['contact_skype']) { |
| 159 | - $info .= _MD_CONTACT_SKYPE . ': ' . $contact['contact_skype'] . "\n"; |
|
| 159 | + $info .= _MD_CONTACT_SKYPE.': '.$contact['contact_skype']."\n"; |
|
| 160 | 160 | } |
| 161 | 161 | if ($contact['contact_phone']) { |
| 162 | - $info .= _MD_CONTACT_PHONE . ': ' . $contact['contact_phone'] . "\n"; |
|
| 162 | + $info .= _MD_CONTACT_PHONE.': '.$contact['contact_phone']."\n"; |
|
| 163 | 163 | } |
| 164 | 164 | if ($contact['contact_company']) { |
| 165 | - $info .= _MD_CONTACT_COMPANY . ': ' . $contact['contact_company'] . "\n"; |
|
| 165 | + $info .= _MD_CONTACT_COMPANY.': '.$contact['contact_company']."\n"; |
|
| 166 | 166 | } |
| 167 | 167 | if ($contact['contact_location']) { |
| 168 | - $info .= _MD_CONTACT_LOCATION . ': ' . $contact['contact_location'] . "\n"; |
|
| 168 | + $info .= _MD_CONTACT_LOCATION.': '.$contact['contact_location']."\n"; |
|
| 169 | 169 | } |
| 170 | 170 | if ($contact['contact_address']) { |
| 171 | - $info .= _MD_CONTACT_ADDRESS . ': ' . $contact['contact_address'] . "\n"; |
|
| 171 | + $info .= _MD_CONTACT_ADDRESS.': '.$contact['contact_address']."\n"; |
|
| 172 | 172 | } |
| 173 | 173 | if ('' !== $info) { |
| 174 | - $info = "\n" . $info . "\n"; |
|
| 174 | + $info = "\n".$info."\n"; |
|
| 175 | 175 | } |
| 176 | 176 | |
| 177 | 177 | $body = \str_replace('{BODY}', \html_entity_decode($contact['contact_message'], \ENT_QUOTES, 'UTF-8'), \_MD_CONTACT_MAIL_BODY); |
@@ -204,28 +204,28 @@ discard block |
||
| 204 | 204 | |
| 205 | 205 | $info = ''; |
| 206 | 206 | if ($contact['contact_url']) { |
| 207 | - $info .= _MD_CONTACT_URL . ': ' . $contact['contact_url'] . "\n"; |
|
| 207 | + $info .= _MD_CONTACT_URL.': '.$contact['contact_url']."\n"; |
|
| 208 | 208 | } |
| 209 | 209 | if ($contact['contact_icq']) { |
| 210 | - $info .= _MD_CONTACT_ICQ . ': ' . $contact['contact_icq'] . "\n"; |
|
| 210 | + $info .= _MD_CONTACT_ICQ.': '.$contact['contact_icq']."\n"; |
|
| 211 | 211 | } |
| 212 | 212 | if ($contact['contact_skype']) { |
| 213 | - $info .= _MD_CONTACT_SKYPE . ': ' . $contact['contact_skype'] . "\n"; |
|
| 213 | + $info .= _MD_CONTACT_SKYPE.': '.$contact['contact_skype']."\n"; |
|
| 214 | 214 | } |
| 215 | 215 | if ($contact['contact_phone']) { |
| 216 | - $info .= _MD_CONTACT_PHONE . ': ' . $contact['contact_phone'] . "\n"; |
|
| 216 | + $info .= _MD_CONTACT_PHONE.': '.$contact['contact_phone']."\n"; |
|
| 217 | 217 | } |
| 218 | 218 | if ($contact['contact_company']) { |
| 219 | - $info .= _MD_CONTACT_COMPANY . ': ' . $contact['contact_company'] . "\n"; |
|
| 219 | + $info .= _MD_CONTACT_COMPANY.': '.$contact['contact_company']."\n"; |
|
| 220 | 220 | } |
| 221 | 221 | if ($contact['contact_location']) { |
| 222 | - $info .= _MD_CONTACT_LOCATION . ': ' . $contact['contact_location'] . "\n"; |
|
| 222 | + $info .= _MD_CONTACT_LOCATION.': '.$contact['contact_location']."\n"; |
|
| 223 | 223 | } |
| 224 | 224 | if ($contact['contact_address']) { |
| 225 | - $info .= _MD_CONTACT_ADDRESS . ': ' . $contact['contact_address'] . "\n"; |
|
| 225 | + $info .= _MD_CONTACT_ADDRESS.': '.$contact['contact_address']."\n"; |
|
| 226 | 226 | } |
| 227 | 227 | if ('' !== $info) { |
| 228 | - $info = "\n" . $info . "\n"; |
|
| 228 | + $info = "\n".$info."\n"; |
|
| 229 | 229 | } |
| 230 | 230 | |
| 231 | 231 | $body = \str_replace('{NAME}', \html_entity_decode($contact['contact_name'], \ENT_QUOTES, 'UTF-8'), _MD_CONTACT_MAILCONFIRM_BODY); |
@@ -312,7 +312,7 @@ discard block |
||
| 312 | 312 | $criteria = new \CriteriaCompo(); |
| 313 | 313 | $criteria->add(new \Criteria('contact_cid', $contact_id)); |
| 314 | 314 | $criteria->add(new \Criteria('contact_type', 'Contact')); |
| 315 | - $contacts =& $this->getObjects($criteria, false); |
|
| 315 | + $contacts = & $this->getObjects($criteria, false); |
|
| 316 | 316 | if ($contacts) { |
| 317 | 317 | $ret = []; |
| 318 | 318 | /** @var Contact $root */ |
@@ -343,7 +343,7 @@ discard block |
||
| 343 | 343 | $criteria->setOrder($contact['order']); |
| 344 | 344 | $criteria->setStart($contact['start']); |
| 345 | 345 | $criteria->setLimit($contact['limit']); |
| 346 | - $contacts =& $this->getObjects($criteria, false); |
|
| 346 | + $contacts = & $this->getObjects($criteria, false); |
|
| 347 | 347 | if ($contacts) { |
| 348 | 348 | /** @var Contact $root */ |
| 349 | 349 | foreach ($contacts as $root) { |
@@ -483,7 +483,7 @@ discard block |
||
| 483 | 483 | } |
| 484 | 484 | $criteria->setSort('contact_create'); |
| 485 | 485 | $criteria->setOrder('DESC'); |
| 486 | - $contacts =& $this->getObjects($criteria, false); |
|
| 486 | + $contacts = & $this->getObjects($criteria, false); |
|
| 487 | 487 | if ($contacts) { |
| 488 | 488 | /** @var Contact $root */ |
| 489 | 489 | foreach ($contacts as $root) { |