@@ -1,9 +1,9 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
| 3 | - die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
|
| 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 | if(!$modx->hasPermission('edit_web_user')) { |
| 6 | - $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 6 | + $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // initialize page view state - the $_PAGE object |
@@ -11,12 +11,12 @@ discard block |
||
| 11 | 11 | |
| 12 | 12 | // get and save search string |
| 13 | 13 | if($_REQUEST['op'] == 'reset') { |
| 14 | - $query = ''; |
|
| 15 | - $_PAGE['vs']['search'] = ''; |
|
| 14 | + $query = ''; |
|
| 15 | + $_PAGE['vs']['search'] = ''; |
|
| 16 | 16 | } else { |
| 17 | - $query = isset($_REQUEST['search']) ? $_REQUEST['search'] : $_PAGE['vs']['search']; |
|
| 18 | - $sqlQuery = $modx->db->escape($query); |
|
| 19 | - $_PAGE['vs']['search'] = $query; |
|
| 17 | + $query = isset($_REQUEST['search']) ? $_REQUEST['search'] : $_PAGE['vs']['search']; |
|
| 18 | + $sqlQuery = $modx->db->escape($query); |
|
| 19 | + $_PAGE['vs']['search'] = $query; |
|
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // get & save listmode |
@@ -120,29 +120,29 @@ discard block |
||
| 120 | 120 | <div class="row"> |
| 121 | 121 | <div class="table-responsive"> |
| 122 | 122 | <?php |
| 123 | - $ds = $modx->db->select("wu.id, wu.username, wua.fullname, wua.email, ELT(wua.gender, '{$_lang['user_male']}', '{$_lang['user_female']}', '{$_lang['user_other']}') AS gender, IF(wua.blocked,'{$_lang['yes']}','-') as 'blocked'", $modx->getFullTableName("web_users") . " wu |
|
| 123 | + $ds = $modx->db->select("wu.id, wu.username, wua.fullname, wua.email, ELT(wua.gender, '{$_lang['user_male']}', '{$_lang['user_female']}', '{$_lang['user_other']}') AS gender, IF(wua.blocked,'{$_lang['yes']}','-') as 'blocked'", $modx->getFullTableName("web_users") . " wu |
|
| 124 | 124 | INNER JOIN " . $modx->getFullTableName("web_user_attributes") . " wua ON wua.internalKey=wu.id", ($sqlQuery ? "(wu.username LIKE '{$sqlQuery}%') OR (wua.fullname LIKE '%{$sqlQuery}%') OR (wua.email LIKE '%{$sqlQuery}%')" : ""), 'username'); |
| 125 | - include_once MODX_MANAGER_PATH . "includes/controls/datagrid.class.php"; |
|
| 126 | - $grd = new DataGrid('', $ds, $number_of_results); // set page size to 0 t show all items |
|
| 127 | - $grd->noRecordMsg = $_lang["no_records_found"]; |
|
| 128 | - $grd->cssClass = "table data"; |
|
| 129 | - $grd->columnHeaderClass = "tableHeader"; |
|
| 130 | - $grd->itemClass = "tableItem"; |
|
| 131 | - $grd->altItemClass = "tableAltItem"; |
|
| 132 | - $grd->fields = "id,username,fullname,email,gender,blocked"; |
|
| 133 | - $grd->columns = $_lang["icon"] . " ," . $_lang["name"] . " ," . $_lang["user_full_name"] . " ," . $_lang["email"] . " ," . $_lang["user_gender"] . " ," . $_lang["user_block"]; |
|
| 134 | - $grd->colWidths = "1%,,,,1%,1%"; |
|
| 135 | - $grd->colAligns = "center,,,,center,right' nowrap='nowrap"; |
|
| 136 | - $grd->colTypes = "template:<a class='gridRowIcon' href='javascript:;' onclick='return showContentMenu([+id+],event);' title='" . $_lang["click_to_context"] . "'><i class='" . $_style["icons_user"] . "'></i></a>||template:<a href='index.php?a=88&id=[+id+]' title='" . $_lang["click_to_edit_title"] . "'>[+value+]</a>"; |
|
| 137 | - if($listmode == '1') { |
|
| 138 | - $grd->pageSize = 0; |
|
| 139 | - } |
|
| 140 | - if($_REQUEST['op'] == 'reset') { |
|
| 141 | - $grd->pageNumber = 1; |
|
| 142 | - } |
|
| 143 | - // render grid |
|
| 144 | - echo $grd->render(); |
|
| 145 | - ?> |
|
| 125 | + include_once MODX_MANAGER_PATH . "includes/controls/datagrid.class.php"; |
|
| 126 | + $grd = new DataGrid('', $ds, $number_of_results); // set page size to 0 t show all items |
|
| 127 | + $grd->noRecordMsg = $_lang["no_records_found"]; |
|
| 128 | + $grd->cssClass = "table data"; |
|
| 129 | + $grd->columnHeaderClass = "tableHeader"; |
|
| 130 | + $grd->itemClass = "tableItem"; |
|
| 131 | + $grd->altItemClass = "tableAltItem"; |
|
| 132 | + $grd->fields = "id,username,fullname,email,gender,blocked"; |
|
| 133 | + $grd->columns = $_lang["icon"] . " ," . $_lang["name"] . " ," . $_lang["user_full_name"] . " ," . $_lang["email"] . " ," . $_lang["user_gender"] . " ," . $_lang["user_block"]; |
|
| 134 | + $grd->colWidths = "1%,,,,1%,1%"; |
|
| 135 | + $grd->colAligns = "center,,,,center,right' nowrap='nowrap"; |
|
| 136 | + $grd->colTypes = "template:<a class='gridRowIcon' href='javascript:;' onclick='return showContentMenu([+id+],event);' title='" . $_lang["click_to_context"] . "'><i class='" . $_style["icons_user"] . "'></i></a>||template:<a href='index.php?a=88&id=[+id+]' title='" . $_lang["click_to_edit_title"] . "'>[+value+]</a>"; |
|
| 137 | + if($listmode == '1') { |
|
| 138 | + $grd->pageSize = 0; |
|
| 139 | + } |
|
| 140 | + if($_REQUEST['op'] == 'reset') { |
|
| 141 | + $grd->pageNumber = 1; |
|
| 142 | + } |
|
| 143 | + // render grid |
|
| 144 | + echo $grd->render(); |
|
| 145 | + ?> |
|
| 146 | 146 | </div> |
| 147 | 147 | </div> |
| 148 | 148 | </div> |
@@ -1,9 +1,9 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
| 3 | - die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
|
| 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 | if(!$modx->hasPermission('export_static')) { |
| 6 | - $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 6 | + $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // figure out the base of the server, so we know where to get the documents in order to export them |
@@ -35,11 +35,11 @@ discard block |
||
| 35 | 35 | |
| 36 | 36 | <div class="container container-body"> |
| 37 | 37 | <?php |
| 38 | - if(isset($_POST['export'])) { |
|
| 39 | - $rs = include_once(MODX_MANAGER_PATH . 'processors/export_site.processor.php'); |
|
| 40 | - echo $rs; |
|
| 41 | - } else { |
|
| 42 | - ?> |
|
| 38 | + if(isset($_POST['export'])) { |
|
| 39 | + $rs = include_once(MODX_MANAGER_PATH . 'processors/export_site.processor.php'); |
|
| 40 | + echo $rs; |
|
| 41 | + } else { |
|
| 42 | + ?> |
|
| 43 | 43 | <form action="index.php" method="post" name="exportFrm"> |
| 44 | 44 | <input type="hidden" name="export" value="export" /> |
| 45 | 45 | <input type="hidden" name="a" value="83" /> |
@@ -81,8 +81,8 @@ discard block |
||
| 81 | 81 | </script> |
| 82 | 82 | </form> |
| 83 | 83 | <?php |
| 84 | - } |
|
| 85 | - ?> |
|
| 84 | + } |
|
| 85 | + ?> |
|
| 86 | 86 | </div> |
| 87 | 87 | </div> |
| 88 | 88 | |
@@ -7,8 +7,8 @@ |
||
| 7 | 7 | <div class="sectionHeader">Changelog</div> |
| 8 | 8 | <div class="sectionBody"> |
| 9 | 9 | <?php |
| 10 | - $changeLog = MODX_BASE_PATH . 'assets/docs/changelog.txt'; |
|
| 11 | - if(is_readable($changeLog)) |
|
| 12 | - echo str_replace("\n",'<br>',file_get_contents($changeLog)); |
|
| 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 | 13 | ?> |
| 14 | 14 | </div> |
@@ -1,32 +1,32 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
| 3 | - die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
|
| 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 | if(!$modx->hasPermission('web_access_permissions')) { |
| 6 | - $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 6 | + $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // find all document groups, for the select :) |
| 10 | 10 | $rs = $modx->db->select('*', $modx->getFullTableName('documentgroup_names'), '', 'name'); |
| 11 | 11 | if($modx->db->getRecordCount($rs) < 1) { |
| 12 | - $docgroupselector = "[no groups to add]"; |
|
| 12 | + $docgroupselector = "[no groups to add]"; |
|
| 13 | 13 | } else { |
| 14 | - $docgroupselector = '<select name="docgroup">' . "\n"; |
|
| 15 | - while($row = $modx->db->getRow($rs)) { |
|
| 16 | - $docgroupselector .= "\t" . '<option value="' . $row['id'] . '">' . $row['name'] . "</option>\n"; |
|
| 17 | - } |
|
| 18 | - $docgroupselector .= "</select>\n"; |
|
| 14 | + $docgroupselector = '<select name="docgroup">' . "\n"; |
|
| 15 | + while($row = $modx->db->getRow($rs)) { |
|
| 16 | + $docgroupselector .= "\t" . '<option value="' . $row['id'] . '">' . $row['name'] . "</option>\n"; |
|
| 17 | + } |
|
| 18 | + $docgroupselector .= "</select>\n"; |
|
| 19 | 19 | } |
| 20 | 20 | |
| 21 | 21 | $rs = $modx->db->select('*', $modx->getFullTableName('webgroup_names'), '', 'name'); |
| 22 | 22 | if($modx->db->getRecordCount($rs) < 1) { |
| 23 | - $usrgroupselector = '[no user groups]'; |
|
| 23 | + $usrgroupselector = '[no user groups]'; |
|
| 24 | 24 | } else { |
| 25 | - $usrgroupselector = '<select name="usergroup">' . "\n"; |
|
| 26 | - while($row = $modx->db->getRow($rs)) { |
|
| 27 | - $usrgroupselector .= "\t" . '<option value="' . $row['id'] . '">' . $row['name'] . "</option>\n"; |
|
| 28 | - } |
|
| 29 | - $usrgroupselector .= "</select>\n"; |
|
| 25 | + $usrgroupselector = '<select name="usergroup">' . "\n"; |
|
| 26 | + while($row = $modx->db->getRow($rs)) { |
|
| 27 | + $usrgroupselector .= "\t" . '<option value="' . $row['id'] . '">' . $row['name'] . "</option>\n"; |
|
| 28 | + } |
|
| 29 | + $usrgroupselector .= "</select>\n"; |
|
| 30 | 30 | } |
| 31 | 31 | |
| 32 | 32 | ?> |
@@ -88,24 +88,24 @@ discard block |
||
| 88 | 88 | </form> |
| 89 | 89 | </div> |
| 90 | 90 | <?php |
| 91 | - $rs = $modx->db->select('groupnames.*, users.id AS user_id, users.username user_name ', $modx->getFullTableName('webgroup_names') . " AS groupnames |
|
| 91 | + $rs = $modx->db->select('groupnames.*, users.id AS user_id, users.username user_name ', $modx->getFullTableName('webgroup_names') . " AS groupnames |
|
| 92 | 92 | LEFT JOIN " . $modx->getFullTableName('web_groups') . " AS groups ON groups.webgroup = groupnames.id |
| 93 | 93 | LEFT JOIN " . $modx->getFullTableName('web_users') . " AS users ON users.id = groups.webuser", '', 'groupnames.name, user_name'); |
| 94 | - if($modx->db->getRecordCount($rs) < 1) { |
|
| 95 | - ?> |
|
| 94 | + if($modx->db->getRecordCount($rs) < 1) { |
|
| 95 | + ?> |
|
| 96 | 96 | <div class="text-danger"><?= $_lang['no_groups_found'] ?></div> |
| 97 | 97 | <?php |
| 98 | - } else { |
|
| 99 | - ?> |
|
| 98 | + } else { |
|
| 99 | + ?> |
|
| 100 | 100 | <div class="form-group"> |
| 101 | 101 | <?php |
| 102 | - $pid = ''; |
|
| 103 | - while($row = $modx->db->getRow($rs)) { |
|
| 104 | - if($pid != $row['id']) { |
|
| 105 | - if($pid != '') { |
|
| 106 | - echo '</div><div class="form-group">'; |
|
| 107 | - } |
|
| 108 | - ?> |
|
| 102 | + $pid = ''; |
|
| 103 | + while($row = $modx->db->getRow($rs)) { |
|
| 104 | + if($pid != $row['id']) { |
|
| 105 | + if($pid != '') { |
|
| 106 | + echo '</div><div class="form-group">'; |
|
| 107 | + } |
|
| 108 | + ?> |
|
| 109 | 109 | <form method="post" action="index.php" name="accesspermissions"> |
| 110 | 110 | <input type="hidden" name="a" value="92" /> |
| 111 | 111 | <input type="hidden" name="groupid" value="<?= $row['id'] ?>" /> |
@@ -120,21 +120,21 @@ discard block |
||
| 120 | 120 | </form> |
| 121 | 121 | <?= $_lang['web_access_permissions_users_in_group'] ?> |
| 122 | 122 | <?php |
| 123 | - } |
|
| 124 | - if(!$row['user_id']) { |
|
| 125 | - ?> |
|
| 123 | + } |
|
| 124 | + if(!$row['user_id']) { |
|
| 125 | + ?> |
|
| 126 | 126 | <i><?= $_lang['access_permissions_no_users_in_group'] ?></i> |
| 127 | 127 | <?php |
| 128 | - $pid = $row['id']; |
|
| 129 | - continue; |
|
| 130 | - } |
|
| 131 | - ?> |
|
| 128 | + $pid = $row['id']; |
|
| 129 | + continue; |
|
| 130 | + } |
|
| 131 | + ?> |
|
| 132 | 132 | <?= ($pid == $row['id'] ? ', ' : '') ?><a href="index.php?a=88&id=<?= $row['user_id'] ?>"><?= $row['user_name'] ?></a> |
| 133 | 133 | <?php |
| 134 | - $pid = $row['id']; |
|
| 135 | - } |
|
| 136 | - } |
|
| 137 | - ?> |
|
| 134 | + $pid = $row['id']; |
|
| 135 | + } |
|
| 136 | + } |
|
| 137 | + ?> |
|
| 138 | 138 | </div> |
| 139 | 139 | </div> |
| 140 | 140 | </div> |
@@ -159,24 +159,24 @@ discard block |
||
| 159 | 159 | </form> |
| 160 | 160 | </div> |
| 161 | 161 | <?php |
| 162 | - $rs = $modx->db->select('dgnames.id, dgnames.name, sc.id AS doc_id, sc.pagetitle AS doc_title', $modx->getFullTableName('documentgroup_names') . " AS dgnames |
|
| 162 | + $rs = $modx->db->select('dgnames.id, dgnames.name, sc.id AS doc_id, sc.pagetitle AS doc_title', $modx->getFullTableName('documentgroup_names') . " AS dgnames |
|
| 163 | 163 | LEFT JOIN " . $modx->getFullTableName('document_groups') . " AS dg ON dg.document_group = dgnames.id |
| 164 | 164 | LEFT JOIN " . $modx->getFullTableName('site_content') . " AS sc ON sc.id = dg.document", '', 'dgnames.name, sc.id'); |
| 165 | - if($modx->db->getRecordCount($rs) < 1) { |
|
| 166 | - ?> |
|
| 165 | + if($modx->db->getRecordCount($rs) < 1) { |
|
| 166 | + ?> |
|
| 167 | 167 | <div class="text-danger"><?= $_lang['no_groups_found'] ?></div> |
| 168 | 168 | <?php |
| 169 | - } else { |
|
| 170 | - ?> |
|
| 169 | + } else { |
|
| 170 | + ?> |
|
| 171 | 171 | <div class="form-group"> |
| 172 | 172 | <?php |
| 173 | - $pid = ''; |
|
| 174 | - while($row = $modx->db->getRow($rs)) { |
|
| 175 | - if($pid != $row['id']) { |
|
| 176 | - if($pid != '') { |
|
| 177 | - echo '</div><div class="form-group">'; |
|
| 178 | - } |
|
| 179 | - ?> |
|
| 173 | + $pid = ''; |
|
| 174 | + while($row = $modx->db->getRow($rs)) { |
|
| 175 | + if($pid != $row['id']) { |
|
| 176 | + if($pid != '') { |
|
| 177 | + echo '</div><div class="form-group">'; |
|
| 178 | + } |
|
| 179 | + ?> |
|
| 180 | 180 | <form method="post" action="index.php" name="accesspermissions"> |
| 181 | 181 | <input type="hidden" name="a" value="92" /> |
| 182 | 182 | <input type="hidden" name="groupid" value="<?= $row['id'] ?>" /> |
@@ -191,21 +191,21 @@ discard block |
||
| 191 | 191 | </form> |
| 192 | 192 | <?= $_lang['access_permissions_resources_in_group'] ?> |
| 193 | 193 | <?php |
| 194 | - } |
|
| 195 | - if(!$row['doc_id']) { |
|
| 196 | - ?> |
|
| 194 | + } |
|
| 195 | + if(!$row['doc_id']) { |
|
| 196 | + ?> |
|
| 197 | 197 | <i><?= $_lang['access_permissions_no_resources_in_group'] ?></i> |
| 198 | 198 | <?php |
| 199 | - $pid = $row['id']; |
|
| 200 | - continue; |
|
| 201 | - } |
|
| 202 | - ?> |
|
| 199 | + $pid = $row['id']; |
|
| 200 | + continue; |
|
| 201 | + } |
|
| 202 | + ?> |
|
| 203 | 203 | <?= ($pid == $row['id'] ? ', ' : '') ?><a href="index.php?a=3&id=<?= $row['doc_id'] ?>" title="<?= $modx->htmlspecialchars($row['doc_title']) ?>"><?= $row['doc_id'] ?></a> |
| 204 | 204 | <?php |
| 205 | - $pid = $row['id']; |
|
| 206 | - } |
|
| 207 | - } |
|
| 208 | - ?> |
|
| 205 | + $pid = $row['id']; |
|
| 206 | + } |
|
| 207 | + } |
|
| 208 | + ?> |
|
| 209 | 209 | </div> |
| 210 | 210 | </div> |
| 211 | 211 | </div> |
@@ -217,15 +217,15 @@ discard block |
||
| 217 | 217 | <div class="container container-body"> |
| 218 | 218 | <p class="element-edit-message-tab alert alert-warning"><?= $_lang['access_permissions_links_tab'] ?></p> |
| 219 | 219 | <?php |
| 220 | - $rs = $modx->db->select('groupnames.*, groupacc.id AS link_id, dgnames.id AS dg_id, dgnames.name AS dg_name', $modx->getFullTableName('webgroup_names') . " AS groupnames |
|
| 220 | + $rs = $modx->db->select('groupnames.*, groupacc.id AS link_id, dgnames.id AS dg_id, dgnames.name AS dg_name', $modx->getFullTableName('webgroup_names') . " AS groupnames |
|
| 221 | 221 | LEFT JOIN " . $modx->getFullTableName('webgroup_access') . " AS groupacc ON groupacc.webgroup = groupnames.id |
| 222 | 222 | LEFT JOIN " . $modx->getFullTableName('documentgroup_names') . " AS dgnames ON dgnames.id = groupacc.documentgroup", '', 'name, dg_name'); |
| 223 | - if($modx->db->getRecordCount($rs) < 1) { |
|
| 224 | - ?> |
|
| 223 | + if($modx->db->getRecordCount($rs) < 1) { |
|
| 224 | + ?> |
|
| 225 | 225 | <div class="text-danger"><?= $_lang['no_groups_found'] ?></div> |
| 226 | 226 | <?php |
| 227 | - } else { |
|
| 228 | - ?> |
|
| 227 | + } else { |
|
| 228 | + ?> |
|
| 229 | 229 | <div class="form-group"> |
| 230 | 230 | <b><?= $_lang["access_permissions_group_link"] ?></b> |
| 231 | 231 | <form method="post" action="index.php" name="accesspermissions"> |
@@ -241,38 +241,38 @@ discard block |
||
| 241 | 241 | <hr> |
| 242 | 242 | <ul> |
| 243 | 243 | <?php |
| 244 | - $pid = ''; |
|
| 245 | - while($row = $modx->db->getRow($rs)) { |
|
| 246 | - if($row['id'] != $pid) { |
|
| 247 | - if($pid != '') { |
|
| 248 | - echo '</ul></li>'; |
|
| 249 | - } // close previous one |
|
| 250 | - ?> |
|
| 244 | + $pid = ''; |
|
| 245 | + while($row = $modx->db->getRow($rs)) { |
|
| 246 | + if($row['id'] != $pid) { |
|
| 247 | + if($pid != '') { |
|
| 248 | + echo '</ul></li>'; |
|
| 249 | + } // close previous one |
|
| 250 | + ?> |
|
| 251 | 251 | <li><b><?= $row['name'] ?></b></li> |
| 252 | 252 | <?php |
| 253 | - if(!$row['dg_id']) { |
|
| 254 | - echo '<i>' . $_lang['no_groups_found'] . '</i></li>'; |
|
| 255 | - $pid = ''; |
|
| 256 | - continue; |
|
| 257 | - } else { |
|
| 258 | - echo '<ul>'; |
|
| 259 | - } |
|
| 260 | - } |
|
| 261 | - if(!$row['dg_id']) { |
|
| 262 | - continue; |
|
| 263 | - } |
|
| 264 | - ?> |
|
| 253 | + if(!$row['dg_id']) { |
|
| 254 | + echo '<i>' . $_lang['no_groups_found'] . '</i></li>'; |
|
| 255 | + $pid = ''; |
|
| 256 | + continue; |
|
| 257 | + } else { |
|
| 258 | + echo '<ul>'; |
|
| 259 | + } |
|
| 260 | + } |
|
| 261 | + if(!$row['dg_id']) { |
|
| 262 | + continue; |
|
| 263 | + } |
|
| 264 | + ?> |
|
| 265 | 265 | <li><?= $row['dg_name'] ?> |
| 266 | 266 | <small><i>(<a class="text-danger" href="index.php?a=92&coupling=<?= $row['link_id'] ?>&operation=remove_document_group_from_user_group"><?= $_lang['remove'] ?></a>)</i></small> |
| 267 | 267 | </li> |
| 268 | 268 | <?php |
| 269 | - $pid = $row['id']; |
|
| 270 | - } |
|
| 271 | - ?> |
|
| 269 | + $pid = $row['id']; |
|
| 270 | + } |
|
| 271 | + ?> |
|
| 272 | 272 | </ul> |
| 273 | 273 | <?php |
| 274 | - } |
|
| 275 | - ?> |
|
| 274 | + } |
|
| 275 | + ?> |
|
| 276 | 276 | </div> |
| 277 | 277 | </div> |
| 278 | 278 | |
@@ -1,9 +1,9 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
| 3 | - die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
|
| 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 | if(!$modx->hasPermission('edit_user')) { |
| 6 | - $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 6 | + $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | ?> |
@@ -18,14 +18,14 @@ discard block |
||
| 18 | 18 | <div class="form-group"><?= $_lang['role_management_msg'] ?> <a class="btn btn-secondary btn-sm" href="index.php?a=38"><i class="<?= $_style["actions_new"] ?> hide4desktop"></i> <?= $_lang['new_role'] ?></a></div> |
| 19 | 19 | <div class="form-group"> |
| 20 | 20 | <?php |
| 21 | - $rs = $modx->db->select('name, id, description', $modx->getFullTableName('user_roles'), '', 'name'); |
|
| 22 | - $limit = $modx->db->getRecordCount($rs); |
|
| 23 | - if($limit < 1) { |
|
| 24 | - ?> |
|
| 21 | + $rs = $modx->db->select('name, id, description', $modx->getFullTableName('user_roles'), '', 'name'); |
|
| 22 | + $limit = $modx->db->getRecordCount($rs); |
|
| 23 | + if($limit < 1) { |
|
| 24 | + ?> |
|
| 25 | 25 | <p><?= $_lang["no_records_found"] ?></p> |
| 26 | 26 | <?php |
| 27 | - } else { |
|
| 28 | - ?> |
|
| 27 | + } else { |
|
| 28 | + ?> |
|
| 29 | 29 | <div class="row"> |
| 30 | 30 | <div class="table-responsive"> |
| 31 | 31 | <table class="table data"> |
@@ -37,24 +37,24 @@ discard block |
||
| 37 | 37 | </thead> |
| 38 | 38 | <tbody> |
| 39 | 39 | <?php |
| 40 | - while($row = $modx->db->getRow($rs)) { |
|
| 41 | - if($row['id'] == 1) { |
|
| 42 | - ?> |
|
| 40 | + while($row = $modx->db->getRow($rs)) { |
|
| 41 | + if($row['id'] == 1) { |
|
| 42 | + ?> |
|
| 43 | 43 | <tr class="text-muted disabled"> |
| 44 | 44 | <td><b><?= $row['name'] ?></b></td> |
| 45 | 45 | <td><span><?= $_lang['administrator_role_message'] ?></span></td> |
| 46 | 46 | </tr> |
| 47 | 47 | <?php |
| 48 | - } else { |
|
| 49 | - ?> |
|
| 48 | + } else { |
|
| 49 | + ?> |
|
| 50 | 50 | <tr> |
| 51 | 51 | <td><a class="text-primary" href="index.php?id=<?= $row['id'] ?>&a=35"><?= $row['name'] ?></a></td> |
| 52 | 52 | <td><?= $row['description'] ?></td> |
| 53 | 53 | </tr> |
| 54 | 54 | <?php |
| 55 | - } |
|
| 56 | - } |
|
| 57 | - ?> |
|
| 55 | + } |
|
| 56 | + } |
|
| 57 | + ?> |
|
| 58 | 58 | </tbody> |
| 59 | 59 | </table> |
| 60 | 60 | </div> |
@@ -4,24 +4,24 @@ discard block |
||
| 4 | 4 | } |
| 5 | 5 | |
| 6 | 6 | if(!$modx->hasPermission('category_manager')) { |
| 7 | - $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 7 | + $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 8 | 8 | } |
| 9 | 9 | |
| 10 | 10 | $_module_params = array( |
| 11 | - 'module_version' => '1.0.0', |
|
| 12 | - 'module_params' => '', |
|
| 13 | - 'module_id' => $_GET['id'], |
|
| 14 | - 'package_name' => 'Module_Categories_Manager', |
|
| 15 | - 'native_language' => 'de', |
|
| 16 | - 'name' => 'Categories Manager', |
|
| 17 | - 'dirname' => $site_manager_url, |
|
| 18 | - 'url' => 'index.php?a=120&id=' . $_GET['id'], |
|
| 19 | - 'path' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR, |
|
| 20 | - 'inc_dir' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR . 'inc' . DIRECTORY_SEPARATOR, |
|
| 21 | - 'languages_dir' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR . 'lang' . DIRECTORY_SEPARATOR, |
|
| 22 | - 'views_dir' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR . 'skin' . DIRECTORY_SEPARATOR, |
|
| 23 | - 'request_key' => 'module_categories_manager', |
|
| 24 | - 'messages' => array() |
|
| 11 | + 'module_version' => '1.0.0', |
|
| 12 | + 'module_params' => '', |
|
| 13 | + 'module_id' => $_GET['id'], |
|
| 14 | + 'package_name' => 'Module_Categories_Manager', |
|
| 15 | + 'native_language' => 'de', |
|
| 16 | + 'name' => 'Categories Manager', |
|
| 17 | + 'dirname' => $site_manager_url, |
|
| 18 | + 'url' => 'index.php?a=120&id=' . $_GET['id'], |
|
| 19 | + 'path' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR, |
|
| 20 | + 'inc_dir' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR . 'inc' . DIRECTORY_SEPARATOR, |
|
| 21 | + 'languages_dir' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR . 'lang' . DIRECTORY_SEPARATOR, |
|
| 22 | + 'views_dir' => realpath( dirname(__FILE__) ) . DIRECTORY_SEPARATOR . 'category_mgr' . DIRECTORY_SEPARATOR . 'skin' . DIRECTORY_SEPARATOR, |
|
| 23 | + 'request_key' => 'module_categories_manager', |
|
| 24 | + 'messages' => array() |
|
| 25 | 25 | ); |
| 26 | 26 | |
| 27 | 27 | require_once $_module_params['inc_dir'] . 'Module_Categories_Manager.php'; |
@@ -30,7 +30,7 @@ discard block |
||
| 30 | 30 | // assign module_params to internal params |
| 31 | 31 | foreach( $_module_params as $param => $value ) |
| 32 | 32 | { |
| 33 | - $cm->set( $param, $value ); |
|
| 33 | + $cm->set( $param, $value ); |
|
| 34 | 34 | } |
| 35 | 35 | |
| 36 | 36 | // catch the request actions |
@@ -38,8 +38,8 @@ discard block |
||
| 38 | 38 | |
| 39 | 39 | if( !$categories = $cm->getCategories() ) |
| 40 | 40 | { |
| 41 | - setcookie('webfxtab_manage-categories-pane', 0 ); |
|
| 42 | - $cm->addMessage( $cm->txt('Currently no categories available... JUST ADD A NEW ONE!'), 'global' ); |
|
| 41 | + setcookie('webfxtab_manage-categories-pane', 0 ); |
|
| 42 | + $cm->addMessage( $cm->txt('Currently no categories available... JUST ADD A NEW ONE!'), 'global' ); |
|
| 43 | 43 | } |
| 44 | 44 | |
| 45 | 45 | $cm->renderView('main', $categories ); |
@@ -1,9 +1,9 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
| 3 | - die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
|
| 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 | if(!$modx->hasPermission('edit_user')) { |
| 6 | - $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 6 | + $modx->webAlertAndQuit($_lang["error_no_privileges"]); |
|
| 7 | 7 | } |
| 8 | 8 | |
| 9 | 9 | // initialize page view state - the $_PAGE object |
@@ -11,12 +11,12 @@ discard block |
||
| 11 | 11 | |
| 12 | 12 | // get and save search string |
| 13 | 13 | if($_REQUEST['op'] == 'reset') { |
| 14 | - $query = ''; |
|
| 15 | - $_PAGE['vs']['search'] = ''; |
|
| 14 | + $query = ''; |
|
| 15 | + $_PAGE['vs']['search'] = ''; |
|
| 16 | 16 | } else { |
| 17 | - $query = isset($_REQUEST['search']) ? $_REQUEST['search'] : $_PAGE['vs']['search']; |
|
| 18 | - $sqlQuery = $modx->db->escape($query); |
|
| 19 | - $_PAGE['vs']['search'] = $query; |
|
| 17 | + $query = isset($_REQUEST['search']) ? $_REQUEST['search'] : $_PAGE['vs']['search']; |
|
| 18 | + $sqlQuery = $modx->db->escape($query); |
|
| 19 | + $_PAGE['vs']['search'] = $query; |
|
| 20 | 20 | } |
| 21 | 21 | |
| 22 | 22 | // get & save listmode |
@@ -120,55 +120,55 @@ discard block |
||
| 120 | 120 | <div class="row"> |
| 121 | 121 | <div class="table-responsive"> |
| 122 | 122 | <?php |
| 123 | - $where = ""; |
|
| 124 | - if(!$modx->hasPermission('save_role')) { |
|
| 125 | - $where .= (empty($where) ? "" : " AND ") . "mua.role != 1"; |
|
| 126 | - } |
|
| 127 | - if(!empty($sqlQuery)) { |
|
| 128 | - $where .= (empty($where) ? "" : " AND ") . "((mu.username LIKE '{$sqlQuery}%') OR (mua.fullname LIKE '%{$sqlQuery}%') OR (mua.email LIKE '{$sqlQuery}%'))"; |
|
| 129 | - } |
|
| 130 | - $ds = $modx->db->select("mu.id, mu.username, rname.name AS role, mua.fullname, mua.email, ELT(mua.gender, '{$_lang['user_male']}', '{$_lang['user_female']}', '{$_lang['user_other']}') AS gender, IF(mua.blocked,'{$_lang['yes']}','-') as blocked, mua.thislogin", $modx->getFullTableName('manager_users') . " AS mu |
|
| 123 | + $where = ""; |
|
| 124 | + if(!$modx->hasPermission('save_role')) { |
|
| 125 | + $where .= (empty($where) ? "" : " AND ") . "mua.role != 1"; |
|
| 126 | + } |
|
| 127 | + if(!empty($sqlQuery)) { |
|
| 128 | + $where .= (empty($where) ? "" : " AND ") . "((mu.username LIKE '{$sqlQuery}%') OR (mua.fullname LIKE '%{$sqlQuery}%') OR (mua.email LIKE '{$sqlQuery}%'))"; |
|
| 129 | + } |
|
| 130 | + $ds = $modx->db->select("mu.id, mu.username, rname.name AS role, mua.fullname, mua.email, ELT(mua.gender, '{$_lang['user_male']}', '{$_lang['user_female']}', '{$_lang['user_other']}') AS gender, IF(mua.blocked,'{$_lang['yes']}','-') as blocked, mua.thislogin", $modx->getFullTableName('manager_users') . " AS mu |
|
| 131 | 131 | INNER JOIN " . $modx->getFullTableName('user_attributes') . " AS mua ON mua.internalKey=mu.id |
| 132 | 132 | LEFT JOIN " . $modx->getFullTableName('user_roles') . " AS rname ON mua.role=rname.id", $where, 'mua.blocked ASC, mua.thislogin DESC'); |
| 133 | - include_once MODX_MANAGER_PATH . "includes/controls/datagrid.class.php"; |
|
| 134 | - $grd = new DataGrid('', $ds, $modx->config['number_of_results']); // set page size to 0 t show all items |
|
| 135 | - $grd->noRecordMsg = $_lang["no_records_found"]; |
|
| 136 | - $grd->cssClass = "table data"; |
|
| 137 | - $grd->columnHeaderClass = "tableHeader"; |
|
| 138 | - $grd->itemClass = "tableItem"; |
|
| 139 | - $grd->altItemClass = "tableAltItem"; |
|
| 140 | - $grd->fields = "id,username,fullname,role,email,gender,blocked,thislogin"; |
|
| 141 | - $grd->columns = implode(',', array( |
|
| 142 | - $_lang["icon"], |
|
| 143 | - $_lang["name"], |
|
| 144 | - $_lang["user_full_name"], |
|
| 145 | - $_lang['role'], |
|
| 146 | - $_lang["email"], |
|
| 147 | - $_lang["user_gender"], |
|
| 148 | - $_lang["user_block"], |
|
| 149 | - $_lang["login_button"] |
|
| 150 | - )); |
|
| 151 | - $grd->colWidths = "1%,,,,,,1%,1%"; |
|
| 152 | - $grd->colAligns = "center,,,,,center,center,right' nowrap='nowrap"; |
|
| 153 | - $grd->colTypes = implode('||', array( |
|
| 154 | - 'template:<a class="gridRowIcon" href="javascript:;" onclick="return showContentMenu([+id+],event);" title="' . $_lang['click_to_context'] . '"><i class="' . $_style['icons_user'] . '"></i></a>', |
|
| 155 | - 'template:<a href="index.php?a=12&id=[+id+]" title="' . $_lang['click_to_edit_title'] . '">[+value+]</a>', |
|
| 156 | - 'template:[+fullname+]', |
|
| 157 | - 'template:[+role+]', |
|
| 158 | - 'template:[+email+]', |
|
| 159 | - 'template:[+gender+]', |
|
| 160 | - 'template:[+blocked+]', |
|
| 161 | - 'date: ' . $modx->toDateFormat('[+thislogin+]', 'formatOnly') . ' %H:%M' |
|
| 162 | - )); |
|
| 163 | - if($listmode == '1') { |
|
| 164 | - $grd->pageSize = 0; |
|
| 165 | - } |
|
| 166 | - if($_REQUEST['op'] == 'reset') { |
|
| 167 | - $grd->pageNumber = 1; |
|
| 168 | - } |
|
| 169 | - // render grid |
|
| 170 | - echo $grd->render(); |
|
| 171 | - ?> |
|
| 133 | + include_once MODX_MANAGER_PATH . "includes/controls/datagrid.class.php"; |
|
| 134 | + $grd = new DataGrid('', $ds, $modx->config['number_of_results']); // set page size to 0 t show all items |
|
| 135 | + $grd->noRecordMsg = $_lang["no_records_found"]; |
|
| 136 | + $grd->cssClass = "table data"; |
|
| 137 | + $grd->columnHeaderClass = "tableHeader"; |
|
| 138 | + $grd->itemClass = "tableItem"; |
|
| 139 | + $grd->altItemClass = "tableAltItem"; |
|
| 140 | + $grd->fields = "id,username,fullname,role,email,gender,blocked,thislogin"; |
|
| 141 | + $grd->columns = implode(',', array( |
|
| 142 | + $_lang["icon"], |
|
| 143 | + $_lang["name"], |
|
| 144 | + $_lang["user_full_name"], |
|
| 145 | + $_lang['role'], |
|
| 146 | + $_lang["email"], |
|
| 147 | + $_lang["user_gender"], |
|
| 148 | + $_lang["user_block"], |
|
| 149 | + $_lang["login_button"] |
|
| 150 | + )); |
|
| 151 | + $grd->colWidths = "1%,,,,,,1%,1%"; |
|
| 152 | + $grd->colAligns = "center,,,,,center,center,right' nowrap='nowrap"; |
|
| 153 | + $grd->colTypes = implode('||', array( |
|
| 154 | + 'template:<a class="gridRowIcon" href="javascript:;" onclick="return showContentMenu([+id+],event);" title="' . $_lang['click_to_context'] . '"><i class="' . $_style['icons_user'] . '"></i></a>', |
|
| 155 | + 'template:<a href="index.php?a=12&id=[+id+]" title="' . $_lang['click_to_edit_title'] . '">[+value+]</a>', |
|
| 156 | + 'template:[+fullname+]', |
|
| 157 | + 'template:[+role+]', |
|
| 158 | + 'template:[+email+]', |
|
| 159 | + 'template:[+gender+]', |
|
| 160 | + 'template:[+blocked+]', |
|
| 161 | + 'date: ' . $modx->toDateFormat('[+thislogin+]', 'formatOnly') . ' %H:%M' |
|
| 162 | + )); |
|
| 163 | + if($listmode == '1') { |
|
| 164 | + $grd->pageSize = 0; |
|
| 165 | + } |
|
| 166 | + if($_REQUEST['op'] == 'reset') { |
|
| 167 | + $grd->pageNumber = 1; |
|
| 168 | + } |
|
| 169 | + // render grid |
|
| 170 | + echo $grd->render(); |
|
| 171 | + ?> |
|
| 172 | 172 | </div> |
| 173 | 173 | </div> |
| 174 | 174 | </div> |
@@ -1,16 +1,16 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
| 3 | - die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
|
| 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 | |
| 6 | 6 | if(isset($_REQUEST['id'])) { |
| 7 | - $id = (int) $_REQUEST['id']; |
|
| 7 | + $id = (int) $_REQUEST['id']; |
|
| 8 | 8 | } else { |
| 9 | - $id = 0; |
|
| 9 | + $id = 0; |
|
| 10 | 10 | } |
| 11 | 11 | |
| 12 | 12 | if(isset($_GET['opened'])) { |
| 13 | - $_SESSION['openedArray'] = $_GET['opened']; |
|
| 13 | + $_SESSION['openedArray'] = $_GET['opened']; |
|
| 14 | 14 | } |
| 15 | 15 | |
| 16 | 16 | $url = $modx->config['site_url']; |
@@ -23,17 +23,17 @@ discard block |
||
| 23 | 23 | |
| 24 | 24 | // Get access permissions |
| 25 | 25 | if($_SESSION['mgrDocgroups']) { |
| 26 | - $docgrp = implode(",", $_SESSION['mgrDocgroups']); |
|
| 26 | + $docgrp = implode(",", $_SESSION['mgrDocgroups']); |
|
| 27 | 27 | } |
| 28 | 28 | $access = "1='" . $_SESSION['mgrRole'] . "' OR sc.privatemgr=0" . (!$docgrp ? "" : " OR dg.document_group IN ($docgrp)"); |
| 29 | 29 | |
| 30 | 30 | // |
| 31 | 31 | if($_SESSION['tree_show_only_folders']) { |
| 32 | - $parent = $id ? ($modx->db->getValue("SELECT parent FROM " . $tbl_site_content . " WHERE id=$id LIMIT 1")) : 0; |
|
| 33 | - $isfolder = $modx->db->getValue("SELECT isfolder FROM " . $tbl_site_content . " WHERE id=$id LIMIT 1"); |
|
| 34 | - if(!$isfolder && $parent != 0) { |
|
| 35 | - $id = $_REQUEST['id'] = $parent; |
|
| 36 | - } |
|
| 32 | + $parent = $id ? ($modx->db->getValue("SELECT parent FROM " . $tbl_site_content . " WHERE id=$id LIMIT 1")) : 0; |
|
| 33 | + $isfolder = $modx->db->getValue("SELECT isfolder FROM " . $tbl_site_content . " WHERE id=$id LIMIT 1"); |
|
| 34 | + if(!$isfolder && $parent != 0) { |
|
| 35 | + $id = $_REQUEST['id'] = $parent; |
|
| 36 | + } |
|
| 37 | 37 | } |
| 38 | 38 | |
| 39 | 39 | // Get the document content |
@@ -41,7 +41,7 @@ discard block |
||
| 41 | 41 | LEFT JOIN {$tbl_document_groups} AS dg ON dg.document = sc.id", "sc.id ='{$id}' AND ({$access})"); |
| 42 | 42 | $content = $modx->db->getRow($rs); |
| 43 | 43 | if(!$content) { |
| 44 | - $modx->webAlertAndQuit($_lang["access_permission_denied"]); |
|
| 44 | + $modx->webAlertAndQuit($_lang["access_permission_denied"]); |
|
| 45 | 45 | } |
| 46 | 46 | |
| 47 | 47 | /** |
@@ -85,134 +85,134 @@ discard block |
||
| 85 | 85 | $filter_sort = ''; |
| 86 | 86 | $filter_dir = ''; |
| 87 | 87 | if($numRecords > 0) { |
| 88 | - $filter_sort = '<select size="1" name="sort" class="form-control form-control-sm" onchange="document.location=\'index.php?a=3&id=' . $id . '&dir=' . $dir . '&sort=\'+this.options[this.selectedIndex].value">' . '<option value="createdon"' . (($sort == 'createdon') ? ' selected' : '') . '>' . $_lang['createdon'] . '</option>' . '<option value="pub_date"' . (($sort == 'pub_date') ? ' selected' : '') . '>' . $_lang["page_data_publishdate"] . '</option>' . '<option value="pagetitle"' . (($sort == 'pagetitle') ? ' selected' : '') . '>' . $_lang['pagetitle'] . '</option>' . '<option value="menuindex"' . (($sort == 'menuindex') ? ' selected' : '') . '>' . $_lang['resource_opt_menu_index'] . '</option>' . //******** resource_opt_is_published - // |
|
| 89 | - '<option value="published"' . (($sort == 'published') ? ' selected' : '') . '>' . $_lang['resource_opt_is_published'] . '</option>' . //********// |
|
| 90 | - '</select>'; |
|
| 91 | - $filter_dir = '<select size="1" name="dir" class="form-control form-control-sm" onchange="document.location=\'index.php?a=3&id=' . $id . '&sort=' . $sort . '&dir=\'+this.options[this.selectedIndex].value">' . '<option value="DESC"' . (($dir == 'DESC') ? ' selected' : '') . '>' . $_lang['sort_desc'] . '</option>' . '<option value="ASC"' . (($dir == 'ASC') ? ' selected' : '') . '>' . $_lang['sort_asc'] . '</option>' . '</select>'; |
|
| 92 | - $resource = $modx->db->makeArray($rs); |
|
| 93 | - |
|
| 94 | - // CSS style for table |
|
| 95 | - // $tableClass = 'grid'; |
|
| 96 | - // $rowHeaderClass = 'gridHeader'; |
|
| 97 | - // $rowRegularClass = 'gridItem'; |
|
| 98 | - // $rowAlternateClass = 'gridAltItem'; |
|
| 99 | - $tableClass = 'table data nowrap'; |
|
| 100 | - $columnHeaderClass = array( |
|
| 101 | - 'text-center', |
|
| 102 | - 'text-left', |
|
| 103 | - 'text-center', |
|
| 104 | - 'text-center', |
|
| 105 | - 'text-center', |
|
| 106 | - 'text-center' |
|
| 107 | - ); |
|
| 108 | - |
|
| 109 | - |
|
| 110 | - $modx->table->setTableClass($tableClass); |
|
| 111 | - $modx->table->setColumnHeaderClass($columnHeaderClass); |
|
| 112 | - // $modx->table->setRowHeaderClass($rowHeaderClass); |
|
| 113 | - // $modx->table->setRowRegularClass($rowRegularClass); |
|
| 114 | - // $modx->table->setRowAlternateClass($rowAlternateClass); |
|
| 115 | - |
|
| 116 | - // Table header |
|
| 117 | - $listTableHeader = array( |
|
| 118 | - 'docid' => $_lang['id'], |
|
| 119 | - 'title' => $_lang['resource_title'], |
|
| 120 | - 'createdon' => $_lang['createdon'], |
|
| 121 | - 'pub_date' => $_lang['page_data_publishdate'], |
|
| 122 | - 'status' => $_lang['page_data_status'], |
|
| 123 | - 'edit' => $_lang['mgrlog_action'], |
|
| 124 | - ); |
|
| 125 | - $tbWidth = array( |
|
| 126 | - '1%', |
|
| 127 | - '', |
|
| 128 | - '1%', |
|
| 129 | - '1%', |
|
| 130 | - '1%', |
|
| 131 | - '1%' |
|
| 132 | - ); |
|
| 133 | - $modx->table->setColumnWidths($tbWidth); |
|
| 134 | - |
|
| 135 | - $sd = isset($_REQUEST['dir']) ? '&dir=' . $_REQUEST['dir'] : '&dir=DESC'; |
|
| 136 | - $sb = isset($_REQUEST['sort']) ? '&sort=' . $_REQUEST['sort'] : '&sort=createdon'; |
|
| 137 | - $pg = isset($_REQUEST['page']) ? '&page=' . (int) $_REQUEST['page'] : ''; |
|
| 138 | - $add_path = $sd . $sb . $pg; |
|
| 139 | - |
|
| 140 | - $icons = array( |
|
| 141 | - 'text/html' => $_style['tree_page_html'], |
|
| 142 | - 'text/plain' => $_style['tree_page'], |
|
| 143 | - 'text/xml' => $_style['tree_page_xml'], |
|
| 144 | - 'text/css' => $_style['tree_page_css'], |
|
| 145 | - 'text/javascript' => $_style['tree_page_js'], |
|
| 146 | - 'application/rss+xml' => $_style['tree_page_rss'], |
|
| 147 | - 'application/pdf' => $_style['tree_page_pdf'], |
|
| 148 | - 'application/vnd.ms-word' => $_style['tree_page_word'], |
|
| 149 | - 'application/vnd.ms-excel' => $_style['tree_page_excel'], |
|
| 150 | - 'image/gif' => $_style['tree_page_gif'], |
|
| 151 | - 'image/jpg' => $_style['tree_page_jpg'], |
|
| 152 | - 'image/png' => $_style['tree_page_png'] |
|
| 153 | - ); |
|
| 154 | - |
|
| 155 | - $listDocs = array(); |
|
| 156 | - foreach($resource as $k => $children) { |
|
| 157 | - |
|
| 158 | - switch($children['id']) { |
|
| 159 | - case $modx->config['site_start'] : |
|
| 160 | - $icon = $_style['tree_page_home']; |
|
| 161 | - break; |
|
| 162 | - case $modx->config['error_page'] : |
|
| 163 | - $icon = $_style['tree_page_404']; |
|
| 164 | - break; |
|
| 165 | - case $modx->config['site_unavailable_page'] : |
|
| 166 | - $icon = $_style['tree_page_hourglass']; |
|
| 167 | - break; |
|
| 168 | - case $modx->config['unauthorized_page'] : |
|
| 169 | - $icon = $_style['tree_page_info']; |
|
| 170 | - break; |
|
| 171 | - default: |
|
| 172 | - if($children['isfolder']) { |
|
| 173 | - $icon = $_style['tree_folder_new']; |
|
| 174 | - } else { |
|
| 175 | - if(isset($icons[$children['contentType']])) { |
|
| 176 | - $icon = $icons[$children['contentType']]; |
|
| 177 | - } else { |
|
| 178 | - $icon = $_style['tree_page']; |
|
| 179 | - } |
|
| 180 | - } |
|
| 181 | - } |
|
| 182 | - |
|
| 183 | - $private = ($children['privateweb'] || $children['privatemgr'] ? ' private' : ''); |
|
| 184 | - |
|
| 185 | - // дописываем в заголовок класс для неопубликованных плюс по всем ссылкам обратный путь |
|
| 186 | - // для сохранения сортировки |
|
| 187 | - $class = ($children['deleted'] ? 'text-danger text-decoration-through' : (!$children['published'] ? ' font-italic text-muted' : ' publish')); |
|
| 188 | - //$class .= ($children['hidemenu'] ? ' text-muted' : ' text-primary'); |
|
| 189 | - //$class .= ($children['isfolder'] ? ' font-weight-bold' : ''); |
|
| 190 | - if($modx->hasPermission('edit_document')) { |
|
| 191 | - $title = '<span class="doc-item' . $private . '">' . $icon . '<a href="index.php?a=27&id=' . $children['id'] . $add_path . '">' . '<span class="' . $class . '">' . $children['pagetitle'] . '</span></a></span>'; |
|
| 192 | - } else { |
|
| 193 | - $title = '<span class="doc-item' . $private . '">' . $icon . '<span class="' . $class . '">' . $children['pagetitle'] . '</span></span>'; |
|
| 194 | - } |
|
| 195 | - |
|
| 196 | - $icon_pub_unpub = (!$children['published']) ? '<a href="index.php?a=61&id=' . $children['id'] . $add_path . '" title="' . $_lang["publish_resource"] . '"><i class="' . $_style["icons_publish_document"] . '"></i></a>' : '<a href="index.php?a=62&id=' . $children['id'] . $add_path . '" title="' . $_lang["unpublish_resource"] . '"><i class="' . $_style["icons_unpublish_resource"] . '" ></i></a>'; |
|
| 197 | - |
|
| 198 | - $icon_del_undel = (!$children['deleted']) ? '<a onclick="return confirm(\'' . $_lang["confirm_delete_resource"] . '\')" href="index.php?a=6&id=' . $children['id'] . $add_path . '" title="' . $_lang['delete_resource'] . '"><i class="' . $_style["icons_delete_resource"] . '"></i></a>' : '<a onclick="return confirm(\'' . $_lang["confirm_undelete"] . '\')" href="index.php?a=63&id=' . $children['id'] . $add_path . '" title="' . $_lang['undelete_resource'] . '"><i class="' . $_style["icons_undelete_resource"] . '"></i></a>'; |
|
| 199 | - |
|
| 200 | - $listDocs[] = array( |
|
| 201 | - 'docid' => '<div class="text-right">' . $children['id'] . '</div>', |
|
| 202 | - 'title' => $title, |
|
| 203 | - 'createdon' => '<div class="text-right">' . ($modx->toDateFormat($children['createdon'] + $server_offset_time, 'dateOnly')) . '</div>', |
|
| 204 | - 'pub_date' => '<div class="text-right">' . ($children['pub_date'] ? ($modx->toDateFormat($children['pub_date'] + $server_offset_time, 'dateOnly')) : '') . '</div>', |
|
| 205 | - 'status' => '<div class="text-nowrap">' . ($children['published'] == 0 ? '<span class="unpublishedDoc">' . $_lang['page_data_unpublished'] . '</span>' : '<span class="publishedDoc">' . $_lang['page_data_published'] . '</span>') . '</div>', |
|
| 206 | - 'edit' => '<div class="actions text-center text-nowrap">' . ($modx->hasPermission('edit_document') ? '<a href="index.php?a=27&id=' . $children['id'] . $add_path . '" title="' . $_lang['edit'] . '"><i class="' . $_style["icons_edit_resource"] . '"></i></a><a href="index.php?a=51&id=' . $children['id'] . $add_path . '" title="' . $_lang['move'] . '"><i |
|
| 88 | + $filter_sort = '<select size="1" name="sort" class="form-control form-control-sm" onchange="document.location=\'index.php?a=3&id=' . $id . '&dir=' . $dir . '&sort=\'+this.options[this.selectedIndex].value">' . '<option value="createdon"' . (($sort == 'createdon') ? ' selected' : '') . '>' . $_lang['createdon'] . '</option>' . '<option value="pub_date"' . (($sort == 'pub_date') ? ' selected' : '') . '>' . $_lang["page_data_publishdate"] . '</option>' . '<option value="pagetitle"' . (($sort == 'pagetitle') ? ' selected' : '') . '>' . $_lang['pagetitle'] . '</option>' . '<option value="menuindex"' . (($sort == 'menuindex') ? ' selected' : '') . '>' . $_lang['resource_opt_menu_index'] . '</option>' . //******** resource_opt_is_published - // |
|
| 89 | + '<option value="published"' . (($sort == 'published') ? ' selected' : '') . '>' . $_lang['resource_opt_is_published'] . '</option>' . //********// |
|
| 90 | + '</select>'; |
|
| 91 | + $filter_dir = '<select size="1" name="dir" class="form-control form-control-sm" onchange="document.location=\'index.php?a=3&id=' . $id . '&sort=' . $sort . '&dir=\'+this.options[this.selectedIndex].value">' . '<option value="DESC"' . (($dir == 'DESC') ? ' selected' : '') . '>' . $_lang['sort_desc'] . '</option>' . '<option value="ASC"' . (($dir == 'ASC') ? ' selected' : '') . '>' . $_lang['sort_asc'] . '</option>' . '</select>'; |
|
| 92 | + $resource = $modx->db->makeArray($rs); |
|
| 93 | + |
|
| 94 | + // CSS style for table |
|
| 95 | + // $tableClass = 'grid'; |
|
| 96 | + // $rowHeaderClass = 'gridHeader'; |
|
| 97 | + // $rowRegularClass = 'gridItem'; |
|
| 98 | + // $rowAlternateClass = 'gridAltItem'; |
|
| 99 | + $tableClass = 'table data nowrap'; |
|
| 100 | + $columnHeaderClass = array( |
|
| 101 | + 'text-center', |
|
| 102 | + 'text-left', |
|
| 103 | + 'text-center', |
|
| 104 | + 'text-center', |
|
| 105 | + 'text-center', |
|
| 106 | + 'text-center' |
|
| 107 | + ); |
|
| 108 | + |
|
| 109 | + |
|
| 110 | + $modx->table->setTableClass($tableClass); |
|
| 111 | + $modx->table->setColumnHeaderClass($columnHeaderClass); |
|
| 112 | + // $modx->table->setRowHeaderClass($rowHeaderClass); |
|
| 113 | + // $modx->table->setRowRegularClass($rowRegularClass); |
|
| 114 | + // $modx->table->setRowAlternateClass($rowAlternateClass); |
|
| 115 | + |
|
| 116 | + // Table header |
|
| 117 | + $listTableHeader = array( |
|
| 118 | + 'docid' => $_lang['id'], |
|
| 119 | + 'title' => $_lang['resource_title'], |
|
| 120 | + 'createdon' => $_lang['createdon'], |
|
| 121 | + 'pub_date' => $_lang['page_data_publishdate'], |
|
| 122 | + 'status' => $_lang['page_data_status'], |
|
| 123 | + 'edit' => $_lang['mgrlog_action'], |
|
| 124 | + ); |
|
| 125 | + $tbWidth = array( |
|
| 126 | + '1%', |
|
| 127 | + '', |
|
| 128 | + '1%', |
|
| 129 | + '1%', |
|
| 130 | + '1%', |
|
| 131 | + '1%' |
|
| 132 | + ); |
|
| 133 | + $modx->table->setColumnWidths($tbWidth); |
|
| 134 | + |
|
| 135 | + $sd = isset($_REQUEST['dir']) ? '&dir=' . $_REQUEST['dir'] : '&dir=DESC'; |
|
| 136 | + $sb = isset($_REQUEST['sort']) ? '&sort=' . $_REQUEST['sort'] : '&sort=createdon'; |
|
| 137 | + $pg = isset($_REQUEST['page']) ? '&page=' . (int) $_REQUEST['page'] : ''; |
|
| 138 | + $add_path = $sd . $sb . $pg; |
|
| 139 | + |
|
| 140 | + $icons = array( |
|
| 141 | + 'text/html' => $_style['tree_page_html'], |
|
| 142 | + 'text/plain' => $_style['tree_page'], |
|
| 143 | + 'text/xml' => $_style['tree_page_xml'], |
|
| 144 | + 'text/css' => $_style['tree_page_css'], |
|
| 145 | + 'text/javascript' => $_style['tree_page_js'], |
|
| 146 | + 'application/rss+xml' => $_style['tree_page_rss'], |
|
| 147 | + 'application/pdf' => $_style['tree_page_pdf'], |
|
| 148 | + 'application/vnd.ms-word' => $_style['tree_page_word'], |
|
| 149 | + 'application/vnd.ms-excel' => $_style['tree_page_excel'], |
|
| 150 | + 'image/gif' => $_style['tree_page_gif'], |
|
| 151 | + 'image/jpg' => $_style['tree_page_jpg'], |
|
| 152 | + 'image/png' => $_style['tree_page_png'] |
|
| 153 | + ); |
|
| 154 | + |
|
| 155 | + $listDocs = array(); |
|
| 156 | + foreach($resource as $k => $children) { |
|
| 157 | + |
|
| 158 | + switch($children['id']) { |
|
| 159 | + case $modx->config['site_start'] : |
|
| 160 | + $icon = $_style['tree_page_home']; |
|
| 161 | + break; |
|
| 162 | + case $modx->config['error_page'] : |
|
| 163 | + $icon = $_style['tree_page_404']; |
|
| 164 | + break; |
|
| 165 | + case $modx->config['site_unavailable_page'] : |
|
| 166 | + $icon = $_style['tree_page_hourglass']; |
|
| 167 | + break; |
|
| 168 | + case $modx->config['unauthorized_page'] : |
|
| 169 | + $icon = $_style['tree_page_info']; |
|
| 170 | + break; |
|
| 171 | + default: |
|
| 172 | + if($children['isfolder']) { |
|
| 173 | + $icon = $_style['tree_folder_new']; |
|
| 174 | + } else { |
|
| 175 | + if(isset($icons[$children['contentType']])) { |
|
| 176 | + $icon = $icons[$children['contentType']]; |
|
| 177 | + } else { |
|
| 178 | + $icon = $_style['tree_page']; |
|
| 179 | + } |
|
| 180 | + } |
|
| 181 | + } |
|
| 182 | + |
|
| 183 | + $private = ($children['privateweb'] || $children['privatemgr'] ? ' private' : ''); |
|
| 184 | + |
|
| 185 | + // дописываем в заголовок класс для неопубликованных плюс по всем ссылкам обратный путь |
|
| 186 | + // для сохранения сортировки |
|
| 187 | + $class = ($children['deleted'] ? 'text-danger text-decoration-through' : (!$children['published'] ? ' font-italic text-muted' : ' publish')); |
|
| 188 | + //$class .= ($children['hidemenu'] ? ' text-muted' : ' text-primary'); |
|
| 189 | + //$class .= ($children['isfolder'] ? ' font-weight-bold' : ''); |
|
| 190 | + if($modx->hasPermission('edit_document')) { |
|
| 191 | + $title = '<span class="doc-item' . $private . '">' . $icon . '<a href="index.php?a=27&id=' . $children['id'] . $add_path . '">' . '<span class="' . $class . '">' . $children['pagetitle'] . '</span></a></span>'; |
|
| 192 | + } else { |
|
| 193 | + $title = '<span class="doc-item' . $private . '">' . $icon . '<span class="' . $class . '">' . $children['pagetitle'] . '</span></span>'; |
|
| 194 | + } |
|
| 195 | + |
|
| 196 | + $icon_pub_unpub = (!$children['published']) ? '<a href="index.php?a=61&id=' . $children['id'] . $add_path . '" title="' . $_lang["publish_resource"] . '"><i class="' . $_style["icons_publish_document"] . '"></i></a>' : '<a href="index.php?a=62&id=' . $children['id'] . $add_path . '" title="' . $_lang["unpublish_resource"] . '"><i class="' . $_style["icons_unpublish_resource"] . '" ></i></a>'; |
|
| 197 | + |
|
| 198 | + $icon_del_undel = (!$children['deleted']) ? '<a onclick="return confirm(\'' . $_lang["confirm_delete_resource"] . '\')" href="index.php?a=6&id=' . $children['id'] . $add_path . '" title="' . $_lang['delete_resource'] . '"><i class="' . $_style["icons_delete_resource"] . '"></i></a>' : '<a onclick="return confirm(\'' . $_lang["confirm_undelete"] . '\')" href="index.php?a=63&id=' . $children['id'] . $add_path . '" title="' . $_lang['undelete_resource'] . '"><i class="' . $_style["icons_undelete_resource"] . '"></i></a>'; |
|
| 199 | + |
|
| 200 | + $listDocs[] = array( |
|
| 201 | + 'docid' => '<div class="text-right">' . $children['id'] . '</div>', |
|
| 202 | + 'title' => $title, |
|
| 203 | + 'createdon' => '<div class="text-right">' . ($modx->toDateFormat($children['createdon'] + $server_offset_time, 'dateOnly')) . '</div>', |
|
| 204 | + 'pub_date' => '<div class="text-right">' . ($children['pub_date'] ? ($modx->toDateFormat($children['pub_date'] + $server_offset_time, 'dateOnly')) : '') . '</div>', |
|
| 205 | + 'status' => '<div class="text-nowrap">' . ($children['published'] == 0 ? '<span class="unpublishedDoc">' . $_lang['page_data_unpublished'] . '</span>' : '<span class="publishedDoc">' . $_lang['page_data_published'] . '</span>') . '</div>', |
|
| 206 | + 'edit' => '<div class="actions text-center text-nowrap">' . ($modx->hasPermission('edit_document') ? '<a href="index.php?a=27&id=' . $children['id'] . $add_path . '" title="' . $_lang['edit'] . '"><i class="' . $_style["icons_edit_resource"] . '"></i></a><a href="index.php?a=51&id=' . $children['id'] . $add_path . '" title="' . $_lang['move'] . '"><i |
|
| 207 | 207 | class="' . $_style["icons_move_document"] . '"></i></a>' . $icon_pub_unpub : '') . ($modx->hasPermission('delete_document') ? $icon_del_undel : '') . '</div>' |
| 208 | - ); |
|
| 209 | - } |
|
| 208 | + ); |
|
| 209 | + } |
|
| 210 | 210 | |
| 211 | - $modx->table->createPagingNavigation($numRecords, 'a=3&id=' . $content['id'] . '&dir=' . $dir . '&sort=' . $sort); |
|
| 212 | - $children_output = $modx->table->create($listDocs, $listTableHeader, 'index.php?a=3&id=' . $content['id']); |
|
| 211 | + $modx->table->createPagingNavigation($numRecords, 'a=3&id=' . $content['id'] . '&dir=' . $dir . '&sort=' . $sort); |
|
| 212 | + $children_output = $modx->table->create($listDocs, $listTableHeader, 'index.php?a=3&id=' . $content['id']); |
|
| 213 | 213 | } else { |
| 214 | - // No Child documents |
|
| 215 | - $children_output = '<div class="container"><p>' . $_lang['resources_in_container_no'] . '</p></div>'; |
|
| 214 | + // No Child documents |
|
| 215 | + $children_output = '<div class="container"><p>' . $_lang['resources_in_container_no'] . '</p></div>'; |
|
| 216 | 216 | } |
| 217 | 217 | ?> |
| 218 | 218 | <script type="text/javascript"> |
@@ -413,20 +413,20 @@ discard block |
||
| 413 | 413 | <h2 class="tab"><?= $_lang['page_data_source'] ?></h2> |
| 414 | 414 | <script type="text/javascript">docSettings.addTabPage(document.getElementById("tabSource"));</script> |
| 415 | 415 | <?php |
| 416 | - $buffer = ""; |
|
| 417 | - $filename = $modx->config['base_path'] . "assets/cache/docid_" . $id . ".pageCache.php"; |
|
| 418 | - $handle = @fopen($filename, "r"); |
|
| 419 | - if(!$handle) { |
|
| 420 | - $buffer = '<div class="container container-body">' . $_lang['page_data_notcached'] . '</div>'; |
|
| 421 | - } else { |
|
| 422 | - while(!feof($handle)) { |
|
| 423 | - $buffer .= fgets($handle, 4096); |
|
| 424 | - } |
|
| 425 | - fclose($handle); |
|
| 426 | - $buffer = '<div class="navbar navbar-editor">' . $_lang['page_data_cached'] . '</div><div class="section-editor clearfix"><textarea rows="20" wrap="soft">' . $modx->htmlspecialchars($buffer) . "</textarea></div>\n"; |
|
| 427 | - } |
|
| 428 | - echo $buffer; |
|
| 429 | - ?> |
|
| 416 | + $buffer = ""; |
|
| 417 | + $filename = $modx->config['base_path'] . "assets/cache/docid_" . $id . ".pageCache.php"; |
|
| 418 | + $handle = @fopen($filename, "r"); |
|
| 419 | + if(!$handle) { |
|
| 420 | + $buffer = '<div class="container container-body">' . $_lang['page_data_notcached'] . '</div>'; |
|
| 421 | + } else { |
|
| 422 | + while(!feof($handle)) { |
|
| 423 | + $buffer .= fgets($handle, 4096); |
|
| 424 | + } |
|
| 425 | + fclose($handle); |
|
| 426 | + $buffer = '<div class="navbar navbar-editor">' . $_lang['page_data_cached'] . '</div><div class="section-editor clearfix"><textarea rows="20" wrap="soft">' . $modx->htmlspecialchars($buffer) . "</textarea></div>\n"; |
|
| 427 | + } |
|
| 428 | + echo $buffer; |
|
| 429 | + ?> |
|
| 430 | 430 | </div><!-- end tab-page --> |
| 431 | 431 | <?php } ?> |
| 432 | 432 | |
@@ -434,7 +434,7 @@ discard block |
||
| 434 | 434 | |
| 435 | 435 | <?php |
| 436 | 436 | if(isset($_GET['tab']) && is_numeric($_GET['tab'])) { |
| 437 | - echo '<script type="text/javascript"> docSettings.setSelectedIndex( ' . $_GET['tab'] . ' );</script>'; |
|
| 437 | + echo '<script type="text/javascript"> docSettings.setSelectedIndex( ' . $_GET['tab'] . ' );</script>'; |
|
| 438 | 438 | } |
| 439 | 439 | ?> |
| 440 | 440 | |
@@ -1,48 +1,48 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | if( ! defined('IN_MANAGER_MODE') || IN_MANAGER_MODE !== true) { |
| 3 | - die("<b>INCLUDE_ORDERING_ERROR</b><br /><br />Please use the EVO Content Manager instead of accessing this file directly."); |
|
| 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 | |
| 6 | 6 | if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/functions.inc.php')) { |
| 7 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/functions.inc.php'); |
|
| 7 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/functions.inc.php'); |
|
| 8 | 8 | } else { |
| 9 | - include_once(MODX_MANAGER_PATH . 'actions/resources/functions.inc.php'); |
|
| 9 | + include_once(MODX_MANAGER_PATH . 'actions/resources/functions.inc.php'); |
|
| 10 | 10 | } |
| 11 | 11 | if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/mgrResources.class.php')) { |
| 12 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/mgrResources.class.php'); |
|
| 12 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/mgrResources.class.php'); |
|
| 13 | 13 | } else { |
| 14 | - include_once(MODX_MANAGER_PATH . 'actions/resources/mgrResources.class.php'); |
|
| 14 | + include_once(MODX_MANAGER_PATH . 'actions/resources/mgrResources.class.php'); |
|
| 15 | 15 | } |
| 16 | 16 | |
| 17 | 17 | $resources = new mgrResources(); |
| 18 | 18 | |
| 19 | 19 | // Prepare lang-strings for "Lock Elements" |
| 20 | 20 | $unlockTranslations = array( |
| 21 | - 'msg' => $_lang["unlock_element_id_warning"], |
|
| 22 | - 'type1' => $_lang["lock_element_type_1"], |
|
| 23 | - 'type2' => $_lang["lock_element_type_2"], |
|
| 24 | - 'type3' => $_lang["lock_element_type_3"], |
|
| 25 | - 'type4' => $_lang["lock_element_type_4"], |
|
| 26 | - 'type5' => $_lang["lock_element_type_5"], |
|
| 27 | - 'type6' => $_lang["lock_element_type_6"], |
|
| 28 | - 'type7' => $_lang["lock_element_type_7"], |
|
| 29 | - 'type8' => $_lang["lock_element_type_8"] |
|
| 21 | + 'msg' => $_lang["unlock_element_id_warning"], |
|
| 22 | + 'type1' => $_lang["lock_element_type_1"], |
|
| 23 | + 'type2' => $_lang["lock_element_type_2"], |
|
| 24 | + 'type3' => $_lang["lock_element_type_3"], |
|
| 25 | + 'type4' => $_lang["lock_element_type_4"], |
|
| 26 | + 'type5' => $_lang["lock_element_type_5"], |
|
| 27 | + 'type6' => $_lang["lock_element_type_6"], |
|
| 28 | + 'type7' => $_lang["lock_element_type_7"], |
|
| 29 | + 'type8' => $_lang["lock_element_type_8"] |
|
| 30 | 30 | ); |
| 31 | 31 | foreach($unlockTranslations as $key => $value) $unlockTranslations[$key] = iconv($modx->config["modx_charset"], "utf-8", $value); |
| 32 | 32 | |
| 33 | 33 | // Prepare lang-strings for mgrResAction() |
| 34 | 34 | $mraTranslations = array( |
| 35 | - 'create_new' => $_lang["create_new"], |
|
| 36 | - 'edit' => $_lang["edit"], |
|
| 37 | - 'duplicate' => $_lang["duplicate"], |
|
| 38 | - 'remove' => $_lang["remove"], |
|
| 39 | - 'confirm_duplicate_record' => $_lang["confirm_duplicate_record"], |
|
| 40 | - 'confirm_delete_template' => $_lang["confirm_delete_template"], |
|
| 41 | - 'confirm_delete_tmplvars' => $_lang["confirm_delete_tmplvars"], |
|
| 42 | - 'confirm_delete_htmlsnippet' => $_lang["confirm_delete_htmlsnippet"], |
|
| 43 | - 'confirm_delete_snippet' => $_lang["confirm_delete_htmlsnippet"], |
|
| 44 | - 'confirm_delete_plugin' => $_lang["confirm_delete_plugin"], |
|
| 45 | - 'confirm_delete_module' => $_lang["confirm_delete_module"], |
|
| 35 | + 'create_new' => $_lang["create_new"], |
|
| 36 | + 'edit' => $_lang["edit"], |
|
| 37 | + 'duplicate' => $_lang["duplicate"], |
|
| 38 | + 'remove' => $_lang["remove"], |
|
| 39 | + 'confirm_duplicate_record' => $_lang["confirm_duplicate_record"], |
|
| 40 | + 'confirm_delete_template' => $_lang["confirm_delete_template"], |
|
| 41 | + 'confirm_delete_tmplvars' => $_lang["confirm_delete_tmplvars"], |
|
| 42 | + 'confirm_delete_htmlsnippet' => $_lang["confirm_delete_htmlsnippet"], |
|
| 43 | + 'confirm_delete_snippet' => $_lang["confirm_delete_htmlsnippet"], |
|
| 44 | + 'confirm_delete_plugin' => $_lang["confirm_delete_plugin"], |
|
| 45 | + 'confirm_delete_module' => $_lang["confirm_delete_module"], |
|
| 46 | 46 | ); |
| 47 | 47 | foreach($mraTranslations as $key => $value) $mraTranslations[$key] = iconv($modx->config["modx_charset"], "utf-8", $value); |
| 48 | 48 | ?> |
@@ -65,46 +65,46 @@ discard block |
||
| 65 | 65 | </script> |
| 66 | 66 | |
| 67 | 67 | <?php |
| 68 | - if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab1_templates.inc.php')) { |
|
| 69 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab1_templates.inc.php'); |
|
| 70 | - } else { |
|
| 71 | - include_once(MODX_MANAGER_PATH . '/actions/resources/tab1_templates.inc.php'); |
|
| 72 | - } |
|
| 68 | + if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab1_templates.inc.php')) { |
|
| 69 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab1_templates.inc.php'); |
|
| 70 | + } else { |
|
| 71 | + include_once(MODX_MANAGER_PATH . '/actions/resources/tab1_templates.inc.php'); |
|
| 72 | + } |
|
| 73 | 73 | |
| 74 | - if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab2_templatevars.inc.php')) { |
|
| 75 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab2_templatevars.inc.php'); |
|
| 76 | - } else { |
|
| 77 | - include_once(MODX_MANAGER_PATH . '/actions/resources/tab2_templatevars.inc.php'); |
|
| 78 | - } |
|
| 74 | + if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab2_templatevars.inc.php')) { |
|
| 75 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab2_templatevars.inc.php'); |
|
| 76 | + } else { |
|
| 77 | + include_once(MODX_MANAGER_PATH . '/actions/resources/tab2_templatevars.inc.php'); |
|
| 78 | + } |
|
| 79 | 79 | |
| 80 | - if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab3_chunks.inc.php')) { |
|
| 81 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab3_chunks.inc.php'); |
|
| 82 | - } else { |
|
| 83 | - include_once(MODX_MANAGER_PATH . '/actions/resources/tab3_chunks.inc.php'); |
|
| 84 | - } |
|
| 80 | + if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab3_chunks.inc.php')) { |
|
| 81 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab3_chunks.inc.php'); |
|
| 82 | + } else { |
|
| 83 | + include_once(MODX_MANAGER_PATH . '/actions/resources/tab3_chunks.inc.php'); |
|
| 84 | + } |
|
| 85 | 85 | |
| 86 | - if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab4_snippets.inc.php')) { |
|
| 87 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab4_snippets.inc.php'); |
|
| 88 | - } else { |
|
| 89 | - include_once(MODX_MANAGER_PATH . '/actions/resources/tab4_snippets.inc.php'); |
|
| 90 | - } |
|
| 86 | + if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab4_snippets.inc.php')) { |
|
| 87 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab4_snippets.inc.php'); |
|
| 88 | + } else { |
|
| 89 | + include_once(MODX_MANAGER_PATH . '/actions/resources/tab4_snippets.inc.php'); |
|
| 90 | + } |
|
| 91 | 91 | |
| 92 | - if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab5_plugins.inc.php')) { |
|
| 93 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab5_plugins.inc.php'); |
|
| 94 | - } else { |
|
| 95 | - include_once(MODX_MANAGER_PATH . '/actions/resources/tab5_plugins.inc.php'); |
|
| 96 | - } |
|
| 92 | + if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab5_plugins.inc.php')) { |
|
| 93 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab5_plugins.inc.php'); |
|
| 94 | + } else { |
|
| 95 | + include_once(MODX_MANAGER_PATH . '/actions/resources/tab5_plugins.inc.php'); |
|
| 96 | + } |
|
| 97 | 97 | |
| 98 | - if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab6_categoryview.inc.php')) { |
|
| 99 | - include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab6_categoryview.inc.php'); |
|
| 100 | - } else { |
|
| 101 | - include_once(MODX_MANAGER_PATH . '/actions/resources/tab6_categoryview.inc.php'); |
|
| 102 | - } |
|
| 98 | + if(file_exists(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab6_categoryview.inc.php')) { |
|
| 99 | + include_once(MODX_MANAGER_PATH . '/media/style/' . $modx->config['manager_theme'] . '/actions/resources/tab6_categoryview.inc.php'); |
|
| 100 | + } else { |
|
| 101 | + include_once(MODX_MANAGER_PATH . '/actions/resources/tab6_categoryview.inc.php'); |
|
| 102 | + } |
|
| 103 | 103 | |
| 104 | 104 | |
| 105 | - if(is_numeric($_GET['tab'])) { |
|
| 106 | - echo '<script type="text/javascript"> tpResources.setSelectedIndex( ' . $_GET['tab'] . ' );</script>'; |
|
| 107 | - } |
|
| 108 | - ?> |
|
| 105 | + if(is_numeric($_GET['tab'])) { |
|
| 106 | + echo '<script type="text/javascript"> tpResources.setSelectedIndex( ' . $_GET['tab'] . ' );</script>'; |
|
| 107 | + } |
|
| 108 | + ?> |
|
| 109 | 109 | </div> |
| 110 | 110 | </div> |