diff --git a/web/css/file_manager.css b/web/css/file_manager.css index 3a43db98a..b90f1ef12 100644 --- a/web/css/file_manager.css +++ b/web/css/file_manager.css @@ -625,3 +625,102 @@ input[type="checkbox"] { .subcontext-menu li { /*float: left;*/ } + + +.shortcuts { + background: rgba(50, 50, 50, 0.9); + display: inline-block; + position: fixed; + right: 20%; + bottom: 0; + color: #eee; + width: 810px; + border: 1px solid #333; + font-family: arial; + font-size: 13px; +} +.shortcuts .header { + border-bottom: 1px solid #333; + height: 43px; +} +.shortcuts .title { + text-transform: uppercase; + color: #ffcc00; + padding: 7px 0 7px 14px; + display: inline-block; + float: left; + font-size: 11px; + letter-spacing: 3px; + font-weight: bold; + line-height: 30px; +} +.shortcuts .close { + background: url("/images/sprite.png") repeat scroll -408px -469px; + cursor: pointer; + display: inline-block; + float: right; + height: 32px; + padding-top: 11px; + width: 46px; +} +.shortcuts .close:hover { + background-color: #000; +.. +} +.shortcuts .close:active { + background-color: #55c9c0; +} +.shortcuts ul { + list-style-type: none; + padding: 30px 10px; + display: inline-block; + float: left; +} +.shortcuts ul li { + padding: 5px 20px; +} +.shortcuts ul li.step-top { + padding-top: 30px; +} +.shortcuts ul li span { + color: #48F4EF; + display: inline-block; + font-weight: bold; + padding: 0 20px 0 0; + text-align: right; + width: 140px; +} +.shortcuts ul li span.bigger { + font-size: 18px; +} +.shortcuts ul.note { + font-style: italic; + color: #9CA484; + width: 700px; + padding-left: 50px; +} +.shortcuts ul.note a { + color: #9CA484; +} + +.to-shortcuts { + display: inline-block; + position: fixed; + top: 95%; + right: 1%; +} +.l-icon-shortcuts { + display: inline-block; + vertical-align: middle; + background-image: url("/images/sprite.png"); + width: 35px; + height: 35px; + background-position: -283px -68px; + border-radius: 18px; +} +.l-icon-shortcuts:hover { + background-color: #ccc; +} +.l-icon-shortcuts:active { + background-color: #98D5CD; +} diff --git a/web/css/styles.min.css b/web/css/styles.min.css index df532d8c2..db876b977 100644 --- a/web/css/styles.min.css +++ b/web/css/styles.min.css @@ -1867,7 +1867,7 @@ div.l-content > div.l-separator:nth-of-type(4) { } -.l-icon-up-arrow, .l-icon-down-arrow, .l-icon-star, .l-icon-to-top, .l-icon-star-orange, .l-icon-star-blue { +.l-icon-up-arrow, .l-icon-down-arrow, .l-icon-star, .l-icon-to-top, .l-icon-shortcuts, .l-icon-star-orange, .l-icon-star-blue { display: inline-block; vertical-align: middle; background-image: url("/images/sprite.png"); @@ -1928,6 +1928,19 @@ div.l-content > div.l-separator:nth-of-type(4) { background-position: -402px -68px; } +.l-icon-shortcuts { + width: 35px; + height: 35px; + background-position: -283px -68px; + border-radius: 18px; +} +.l-icon-shortcuts:hover { + background-color: #ccc; +} +.l-icon-shortcuts:active { + background-color: #98D5CD; +} + .l-icon-star-orange { width: 13px; height: 13px; @@ -1974,9 +1987,17 @@ div.l-content > div.l-separator:nth-of-type(4) { display: inline-block; position: fixed; top: 92%; - right: 3%; + right: 4%; } +.to-shortcuts { + display: inline-block; + position: fixed; + top: 92%; + right: 1%; +} + + /* #vstobjects { margin-top: -1px; @@ -2737,6 +2758,7 @@ form#vstobjects.suspended { color: #eee; width: 800px; border: 1px solid #333; + font-size: 13px; } .shortcuts .header { border-bottom: 1px solid #333; @@ -2777,7 +2799,7 @@ form#vstobjects.suspended { padding: 5px 20px; } .shortcuts ul li.step-top { - padding-bottom: 30px; + padding-top: 30px; } .shortcuts ul li span { color: #48F4EF; diff --git a/web/edit/file/index.php b/web/edit/file/index.php index 7620d3db0..a09563ae0 100644 --- a/web/edit/file/index.php +++ b/web/edit/file/index.php @@ -57,20 +57,24 @@ if ((!isset($_SESSION['user'])) && (!defined('NO_AUTH_REQUIRED'))) { if ($fn) { $f = fopen ($fn, 'w+'); fwrite($f, $_POST['contents']); + fclose($f); + + chmod($fn, 0644); + if ($f) { //copy($fn, $path); exec (VESTA_CMD . "v-copy-fs-file {$user} {$fn} {$path}", $output, $return_var); $error = check_return_code($return_var, $output); if ($return_var != 0) { - var_dump(VESTA_CMD . "v-copy-fs-file {$user} {$fn} {$path}"); + /*var_dump(VESTA_CMD . "v-copy-fs-file {$user} {$fn} {$path}"); var_dump($path); - var_dump($output); + var_dump($output);*/ die('
Error while saving file
');//echo '0'; } } unlink($fn); - } + } } // $content = file_get_contents($path); diff --git a/web/images/sprite.png b/web/images/sprite.png index cb9be74ea..f3df683ad 100644 Binary files a/web/images/sprite.png and b/web/images/sprite.png differ diff --git a/web/inc/i18n/en.php b/web/inc/i18n/en.php index 3b9b469a7..224921533 100644 --- a/web/inc/i18n/en.php +++ b/web/inc/i18n/en.php @@ -546,4 +546,54 @@ $LANG['en'] = array( 'Create file' => 'Create file', 'Create directory' => 'Create directory', + + 'Add New object' => 'Add New object', + 'Save Form' => 'Save Form', + 'Cancel saving form' => 'Cancel saving form', + 'Go to USER list' => 'Go to USER list', + 'Go to WEB list' => 'Go to WEB list', + 'Go to DNS list' => 'Go to DNS list', + 'Go to MAIL list' => 'Go to MAIL list', + 'Go to DB list' => 'Go to DB list', + 'Go to CRON list' => 'Go to CRON list', + 'Go to BACKUP list' => 'Go to BACKUP list', + 'Focus on search' => 'Focus on search', + 'Display/Close shortcuts' => 'Display/Close shortcuts', + 'Go to Packages' => 'Go to Packages', + 'Go to IP' => 'Go to IP', + 'Go to Graphs' => 'Go to Graphs', + 'Go to Statistic' => 'Go to Statistic', + 'Go to Log' => 'Go to Log', + 'Go to Updates' => 'Go to Updates', + 'Go to Firewall' => 'Go to Firewall', + 'Go to File Manager' => 'Go to File Manager', + 'Go to Server' => 'Go to Server', + + + 'Upload' => 'Upload', + 'New File' => 'New File', + 'New Folder' => 'New Folder', + 'Download' => 'Download', + 'Rename' => 'Rename', + 'Copy' => 'Copy', + 'Archive' => 'Archive', + 'Delete' => 'Delete', + 'Save File (in text editor)' => 'Save File (in text editor)', + 'Display Shortcuts Hel' => 'Display Shortcuts Hel', + 'Close Popup / Cancel' => 'Close Popup / Cancel', + 'Move Cursor Up' => 'Move Cursor Up', + 'Move Cursor Dow' => 'Move Cursor Dow', + 'Switch to Left Tab' => 'Switch to Left Tab', + 'Switch to Right Tab' => 'Switch to Right Tab', + 'Switch Tab' => 'Switch Tab', + 'Go to the Top of File List' => 'Go to the Top of File List', + 'Go to the Last File' => 'Go to the Last File', + 'Open File/Enter Directory' => 'Open File/Enter Directory', + 'Go to Parent Directory' => 'Go to Parent Directory', + 'Select Current File' => 'Select Current File', + 'Select Bunch of Files' => 'Select Bunch of Files', + 'Append File to the Current Selection' => 'Append File to the Current Selection', + 'Select All Files' => 'Select All Files', + 'shortcuts are inspired by magnificent GNU Midnight Commander file manager' => 'shortcuts are inspired by magnificent GNU Midnight Commander file manager', + ); \ No newline at end of file diff --git a/web/js/file_manager.js b/web/js/file_manager.js index f7093c427..b79fbdd34 100644 --- a/web/js/file_manager.js +++ b/web/js/file_manager.js @@ -546,7 +546,7 @@ FM.downloadFileFromSubcontext = function(elm) { FM.openFile = function(dir, box, elm) { var tab = FM.getTabLetter(box); - FM['TAB_'+tab+'_CURRENT_PATH'] = dir; + //FM['TAB_'+tab+'_CURRENT_PATH'] = dir; var elm = $(elm).hasClass('dir') ? $(elm) : $(elm).closest('.dir'); var src = $.parseJSON($(elm).find('.source').val()); @@ -754,11 +754,11 @@ FM.checkBulkStatus = function(bulkStatuses, acc) { if (status == true) { $('#popup .results').html(App.Constants.FM_DONE); - $('.controls p').replaceWith('close
'); + $('.controls').html(''+App.Constants.FM_DONE+'
'); } else { $('#popup .results').html(msg); - $('.controls p').replaceWith('close
'); + $('.controls').html(''+App.Constants.FM_DONE+'
'); } } @@ -795,49 +795,47 @@ FM.humanFileSizeUnit = function(size) { } -FM.bulkCopy = function() { +FM.bulkCopyDo = function() { var acc = $(FM.CURRENT_TAB).find('.dir.selected'); if (acc.length > 0) { //FM.popupClose(); - + var cfr_html = ''; - + var numberOfItems = 0; $.each(acc, function(i, o) { var ref = $(o); var src = $(ref).find('.source').val(); src = $.parseJSON(src); - + if (!FM.isItemPseudo(o)) { cfr_html += ''+App.Constants.FM_CLOSE+'
\ \ '], - popup_bulk: [''+App.Constants.FM_CANCEL+'
\ +'+App.Constants.FM_DELETE+'
\ +'+App.Constants.FM_CANCEL+'
\ +'+App.Constants.FM_COPY+'
\ +