@@ -1,8 +1,8 @@ discard block |
||
1 | 1 | <?php |
2 | -if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
2 | +if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
3 | 3 | die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
4 | 4 | } |
5 | -if (!$modx->hasPermission('logs')) { |
|
5 | +if (!$modx->hasPermission('logs')) { |
|
6 | 6 | $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
7 | 7 | } |
8 | 8 | |
@@ -55,7 +55,7 @@ discard block |
||
55 | 55 | <table class="table data table-sm nowrap"> |
56 | 56 | <tbody> |
57 | 57 | <?php |
58 | - foreach ($serverArr as $key => $value) { |
|
58 | + foreach ($serverArr as $key => $value) { |
|
59 | 59 | ?> |
60 | 60 | <tr> |
61 | 61 | <td width="1%"><?= $key ?></td> |
@@ -98,7 +98,7 @@ discard block |
||
98 | 98 | $sql = "SHOW TABLE STATUS FROM $dbase LIKE '" . $modx->db->escape($modx->db->config['table_prefix']) . "%';"; |
99 | 99 | $rs = $modx->db->query($sql); |
100 | 100 | $i = 0; |
101 | - while ($log_status = $modx->db->getRow($rs)) { |
|
101 | + while ($log_status = $modx->db->getRow($rs)) { |
|
102 | 102 | ?> |
103 | 103 | <tr> |
104 | 104 | <td class="text-primary"><b><?= $log_status['Name'] ?></b></td> |
@@ -110,17 +110,17 @@ discard block |
||
110 | 110 | $modx->db->config['table_prefix'] . 'event_log', |
111 | 111 | $modx->db->config['table_prefix'] . 'manager_log', |
112 | 112 | ); |
113 | - if ($modx->hasPermission('settings') && in_array($log_status['Name'], $truncateable)) { |
|
113 | + if ($modx->hasPermission('settings') && in_array($log_status['Name'], $truncateable)) { |
|
114 | 114 | echo "<td class=\"text-xs-right\">"; |
115 | 115 | echo "<a class=\"text-danger\" href='index.php?a=54&mode=$action&u=" . $log_status['Name'] . "' title='" . $_lang['truncate_table'] . "'>" . $modx->nicesize($log_status['Data_length'] + $log_status['Data_free']) . "</a>"; |
116 | 116 | echo "</td>"; |
117 | - } else { |
|
117 | + } else { |
|
118 | 118 | echo "<td class=\"text-xs-right\">" . $modx->nicesize($log_status['Data_length'] + $log_status['Data_free']) . "</td>"; |
119 | 119 | } |
120 | 120 | |
121 | - if ($modx->hasPermission('settings')) { |
|
121 | + if ($modx->hasPermission('settings')) { |
|
122 | 122 | echo "<td class=\"text-xs-right\">" . ($log_status['Data_free'] > 0 ? "<a class=\"text-danger\" href='index.php?a=54&mode=$action&t=" . $log_status['Name'] . "' title='" . $_lang['optimize_table'] . "' ><span>" . $modx->nicesize($log_status['Data_free']) . "</span></a>" : "-") . "</td>"; |
123 | - } else { |
|
123 | + } else { |
|
124 | 124 | echo "<td class=\"text-xs-right\">" . ($log_status['Data_free'] > 0 ? $modx->nicesize($log_status['Data_free']) : "-") . "</td>"; |
125 | 125 | } |
126 | 126 | ?> |
@@ -1,5 +1,5 @@ discard block |
||
1 | 1 | <?php |
2 | -if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
2 | +if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
3 | 3 | die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
4 | 4 | } |
5 | 5 | $helpBasePath = "actions/help/"; |
@@ -16,9 +16,9 @@ discard block |
||
16 | 16 | </script> |
17 | 17 | |
18 | 18 | <?php |
19 | - if($handle = opendir('actions/help')) { |
|
20 | - while(false !== ($file = readdir($handle))) { |
|
21 | - if($file != "." && $file != ".." && $file != ".svn" && $file != 'index.html' && !is_dir($helpBasePath . $file)) { |
|
19 | + if($handle = opendir('actions/help')) { |
|
20 | + while(false !== ($file = readdir($handle))) { |
|
21 | + if($file != "." && $file != ".." && $file != ".svn" && $file != 'index.html' && !is_dir($helpBasePath . $file)) { |
|
22 | 22 | $help[] = $file; |
23 | 23 | } |
24 | 24 | } |
@@ -27,12 +27,12 @@ discard block |
||
27 | 27 | |
28 | 28 | natcasesort($help); |
29 | 29 | |
30 | - foreach($help as $k => $v) { |
|
30 | + foreach($help as $k => $v) { |
|
31 | 31 | |
32 | 32 | $helpname = substr($v, 0, strrpos($v, '.')); |
33 | 33 | |
34 | 34 | $prefix = substr($helpname, 0, 2); |
35 | - if(is_numeric($prefix)) { |
|
35 | + if(is_numeric($prefix)) { |
|
36 | 36 | $helpname = substr($helpname, 2, strlen($helpname) - 1); |
37 | 37 | } |
38 | 38 |
@@ -18,8 +18,7 @@ |
||
18 | 18 | foreach($notices as $v) { |
19 | 19 | if ($v >= '1.3.0') { |
20 | 20 | $cms = 'EVO'; |
21 | - } |
|
22 | - else { |
|
21 | + } else { |
|
23 | 22 | $cms = 'MODX EVO'; |
24 | 23 | } |
25 | 24 | echo '<div class="sectionHeader"> '.$cms.' '.$v.'</div><div class="sectionBody">'; |
@@ -8,7 +8,8 @@ |
||
8 | 8 | <div class="sectionBody"> |
9 | 9 | <?php |
10 | 10 | $changeLog = MODX_BASE_PATH . 'assets/docs/changelog.txt'; |
11 | - if(is_readable($changeLog)) |
|
12 | - echo str_replace("\n",'<br>',file_get_contents($changeLog)); |
|
13 | -?> |
|
11 | + if(is_readable($changeLog)) { |
|
12 | + echo str_replace("\n",'<br>',file_get_contents($changeLog)); |
|
13 | + } |
|
14 | + ?> |
|
14 | 15 | </div> |
@@ -28,16 +28,14 @@ |
||
28 | 28 | $cm = new Module_Categories_Manager(); |
29 | 29 | |
30 | 30 | // assign module_params to internal params |
31 | -foreach( $_module_params as $param => $value ) |
|
32 | -{ |
|
31 | +foreach( $_module_params as $param => $value ) { |
|
33 | 32 | $cm->set( $param, $value ); |
34 | 33 | } |
35 | 34 | |
36 | 35 | // catch the request actions |
37 | 36 | include_once $cm->get('inc_dir') . 'request_trigger.inc.php'; |
38 | 37 | |
39 | -if( !$categories = $cm->getCategories() ) |
|
40 | -{ |
|
38 | +if( !$categories = $cm->getCategories() ) { |
|
41 | 39 | setcookie('webfxtab_manage-categories-pane', 0 ); |
42 | 40 | $cm->addMessage( $cm->txt('Currently no categories available... JUST ADD A NEW ONE!'), 'global' ); |
43 | 41 | } |
@@ -1,8 +1,8 @@ |
||
1 | 1 | <?php |
2 | -if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
2 | +if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
3 | 3 | die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
4 | 4 | } |
5 | -if(!$modx->hasPermission('change_password')) { |
|
5 | +if(!$modx->hasPermission('change_password')) { |
|
6 | 6 | $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
7 | 7 | } |
8 | 8 | ?> |
@@ -1,8 +1,8 @@ discard block |
||
1 | 1 | <?php |
2 | -if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
2 | +if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
3 | 3 | die("<b>INCLUDE_ORDERING_ERROR</b><br />Please use the EVO Content Manager instead of accessing this file directly."); |
4 | 4 | } |
5 | -if(!$modx->hasPermission('settings')) { |
|
5 | +if(!$modx->hasPermission('settings')) { |
|
6 | 6 | $modx->webAlertAndQuit($_lang['error_no_privileges']); |
7 | 7 | } |
8 | 8 | |
@@ -10,7 +10,7 @@ discard block |
||
10 | 10 | |
11 | 11 | // check to see the edit settings page isn't locked |
12 | 12 | $rs = $modx->db->select('username', $modx->getFullTableName('active_users'), "action=17 AND internalKey!='" . $modx->getLoginUserID() . "'"); |
13 | -if($username = $modx->db->getValue($rs)) { |
|
13 | +if($username = $modx->db->getValue($rs)) { |
|
14 | 14 | $modx->webAlertAndQuit(sprintf($_lang['lock_settings_msg'], $username)); |
15 | 15 | } |
16 | 16 | // end check for lock |
@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | $settings = array(); |
21 | 21 | include_once(MODX_MANAGER_PATH . 'includes/default_config.php'); |
22 | 22 | $rs = $modx->db->select('setting_name, setting_value', '[+prefix+]system_settings'); |
23 | -while($row = $modx->db->getRow($rs)) { |
|
23 | +while($row = $modx->db->getRow($rs)) { |
|
24 | 24 | $settings[$row['setting_name']] = $row['setting_value']; |
25 | 25 | } |
26 | 26 | $settings['filemanager_path'] = preg_replace('@^' . preg_quote(MODX_BASE_PATH) . '@', '[(base_path)]', $settings['filemanager_path']); |
@@ -31,8 +31,8 @@ discard block |
||
31 | 31 | // load languages and keys |
32 | 32 | $lang_keys = array(); |
33 | 33 | $dir = dir('includes/lang'); |
34 | -while($file = $dir->read()) { |
|
35 | - if(strpos($file, '.inc.php') > 0) { |
|
34 | +while($file = $dir->read()) { |
|
35 | + if(strpos($file, '.inc.php') > 0) { |
|
36 | 36 | $endpos = strpos($file, '.'); |
37 | 37 | $languagename = substr($file, 0, $endpos); |
38 | 38 | $lang_keys[$languagename] = get_lang_keys($file); |
@@ -131,6 +131,6 @@ discard block |
||
131 | 131 | }); |
132 | 132 | </script> |
133 | 133 | <?php |
134 | -if(is_numeric($_GET['tab'])) { |
|
134 | +if(is_numeric($_GET['tab'])) { |
|
135 | 135 | echo '<script type="text/javascript">tpSettings.setSelectedIndex( ' . $_GET['tab'] . ' );</script>'; |
136 | 136 | } |
@@ -118,18 +118,18 @@ |
||
118 | 118 | $articul_query = "SELECT `contentid` FROM {$tbl_site_tmplvar_contentvalues} WHERE `value` LIKE '%{$searchfields}%'"; |
119 | 119 | $articul_result = $modx->db->query($articul_query); |
120 | 120 | $articul_id_array = $modx->db->makeArray($articul_result); |
121 | - if(count($articul_id_array)>0){ |
|
121 | + if(count($articul_id_array)>0) { |
|
122 | 122 | $articul_id = ''; |
123 | 123 | $i = 1; |
124 | 124 | foreach( $articul_id_array as $articul ) { |
125 | 125 | $articul_id.=$articul['contentid']; |
126 | - if($i !== count($articul_id_array)){ |
|
126 | + if($i !== count($articul_id_array)) { |
|
127 | 127 | $articul_id.=','; |
128 | 128 | } |
129 | 129 | $i++; |
130 | 130 | } |
131 | 131 | $articul_id_query = " OR sc.id IN ({$articul_id})"; |
132 | - }else{ |
|
132 | + } else { |
|
133 | 133 | $articul_id_query = ''; |
134 | 134 | } |
135 | 135 | /*end search by TV*/ |
@@ -1,8 +1,8 @@ discard block |
||
1 | 1 | <?php |
2 | -if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
2 | +if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
|
3 | 3 | die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
4 | 4 | } |
5 | -if(!$modx->hasPermission('view_eventlog')) { |
|
5 | +if(!$modx->hasPermission('view_eventlog')) { |
|
6 | 6 | $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
7 | 7 | } |
8 | 8 | |
@@ -15,12 +15,12 @@ discard block |
||
15 | 15 | $modx->manager->initPageViewState(); |
16 | 16 | |
17 | 17 | // get and save search string |
18 | -if($_REQUEST['op'] == 'reset') { |
|
18 | +if($_REQUEST['op'] == 'reset') { |
|
19 | 19 | $sqlQuery = $query = ''; |
20 | 20 | $_PAGE['vs']['search'] = ''; |
21 | -} else { |
|
21 | +} else { |
|
22 | 22 | $sqlQuery = $query = isset($_REQUEST['search']) ? $_REQUEST['search'] : $_PAGE['vs']['search']; |
23 | - if(!is_numeric($sqlQuery)) { |
|
23 | + if(!is_numeric($sqlQuery)) { |
|
24 | 24 | $sqlQuery = $modx->db->escape($query); |
25 | 25 | } |
26 | 26 | $_PAGE['vs']['search'] = $query; |
@@ -143,10 +143,10 @@ discard block |
||
143 | 143 | $grd->colWidths = "1%,,1%,1%,1%"; |
144 | 144 | $grd->colAligns = "center,,,center,center"; |
145 | 145 | $grd->colTypes = "template:<a class='gridRowIcon' href='javascript:;' onclick='return showContentMenu([+id+],event);' title='" . $_lang['click_to_context'] . "'><i class='[+icon+]'></i></a>||template:<a href='index.php?a=115&id=[+id+]' title='" . $_lang['click_to_view_details'] . "'>[+source+]</a>||date: " . $modx->toDateFormat(null, 'formatOnly') . ' %I:%M %p'; |
146 | - if($listmode == '1') { |
|
146 | + if($listmode == '1') { |
|
147 | 147 | $grd->pageSize = 0; |
148 | 148 | } |
149 | - if($_REQUEST['op'] == 'reset') { |
|
149 | + if($_REQUEST['op'] == 'reset') { |
|
150 | 150 | $grd->pageNumber = 1; |
151 | 151 | } |
152 | 152 | // render grid |