Skip to content

Commit 7565e82

Browse files
committed
FileManager stuff
1 parent 5c8e3d3 commit 7565e82

File tree

13 files changed

+516
-62
lines changed

13 files changed

+516
-62
lines changed

web/css/file_manager.css

Lines changed: 99 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -625,3 +625,102 @@ input[type="checkbox"] {
625625
.subcontext-menu li {
626626
/*float: left;*/
627627
}
628+
629+
630+
.shortcuts {
631+
background: rgba(50, 50, 50, 0.9);
632+
display: inline-block;
633+
position: fixed;
634+
right: 20%;
635+
bottom: 0;
636+
color: #eee;
637+
width: 810px;
638+
border: 1px solid #333;
639+
font-family: arial;
640+
font-size: 13px;
641+
}
642+
.shortcuts .header {
643+
border-bottom: 1px solid #333;
644+
height: 43px;
645+
}
646+
.shortcuts .title {
647+
text-transform: uppercase;
648+
color: #ffcc00;
649+
padding: 7px 0 7px 14px;
650+
display: inline-block;
651+
float: left;
652+
font-size: 11px;
653+
letter-spacing: 3px;
654+
font-weight: bold;
655+
line-height: 30px;
656+
}
657+
.shortcuts .close {
658+
background: url("/images/sprite.png") repeat scroll -408px -469px;
659+
cursor: pointer;
660+
display: inline-block;
661+
float: right;
662+
height: 32px;
663+
padding-top: 11px;
664+
width: 46px;
665+
}
666+
.shortcuts .close:hover {
667+
background-color: #000;
668+
..
669+
}
670+
.shortcuts .close:active {
671+
background-color: #55c9c0;
672+
}
673+
.shortcuts ul {
674+
list-style-type: none;
675+
padding: 30px 10px;
676+
display: inline-block;
677+
float: left;
678+
}
679+
.shortcuts ul li {
680+
padding: 5px 20px;
681+
}
682+
.shortcuts ul li.step-top {
683+
padding-top: 30px;
684+
}
685+
.shortcuts ul li span {
686+
color: #48F4EF;
687+
display: inline-block;
688+
font-weight: bold;
689+
padding: 0 20px 0 0;
690+
text-align: right;
691+
width: 140px;
692+
}
693+
.shortcuts ul li span.bigger {
694+
font-size: 18px;
695+
}
696+
.shortcuts ul.note {
697+
font-style: italic;
698+
color: #9CA484;
699+
width: 700px;
700+
padding-left: 50px;
701+
}
702+
.shortcuts ul.note a {
703+
color: #9CA484;
704+
}
705+
706+
.to-shortcuts {
707+
display: inline-block;
708+
position: fixed;
709+
top: 95%;
710+
right: 1%;
711+
}
712+
.l-icon-shortcuts {
713+
display: inline-block;
714+
vertical-align: middle;
715+
background-image: url("/images/sprite.png");
716+
width: 35px;
717+
height: 35px;
718+
background-position: -283px -68px;
719+
border-radius: 18px;
720+
}
721+
.l-icon-shortcuts:hover {
722+
background-color: #ccc;
723+
}
724+
.l-icon-shortcuts:active {
725+
background-color: #98D5CD;
726+
}

web/css/styles.min.css

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1867,7 +1867,7 @@ div.l-content > div.l-separator:nth-of-type(4) {
18671867
}
18681868

18691869

1870-
.l-icon-up-arrow, .l-icon-down-arrow, .l-icon-star, .l-icon-to-top, .l-icon-star-orange, .l-icon-star-blue {
1870+
.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 {
18711871
display: inline-block;
18721872
vertical-align: middle;
18731873
background-image: url("/images/sprite.png");
@@ -1928,6 +1928,19 @@ div.l-content > div.l-separator:nth-of-type(4) {
19281928
background-position: -402px -68px;
19291929
}
19301930

1931+
.l-icon-shortcuts {
1932+
width: 35px;
1933+
height: 35px;
1934+
background-position: -283px -68px;
1935+
border-radius: 18px;
1936+
}
1937+
.l-icon-shortcuts:hover {
1938+
background-color: #ccc;
1939+
}
1940+
.l-icon-shortcuts:active {
1941+
background-color: #98D5CD;
1942+
}
1943+
19311944
.l-icon-star-orange {
19321945
width: 13px;
19331946
height: 13px;
@@ -1974,9 +1987,17 @@ div.l-content > div.l-separator:nth-of-type(4) {
19741987
display: inline-block;
19751988
position: fixed;
19761989
top: 92%;
1977-
right: 3%;
1990+
right: 4%;
19781991
}
19791992

1993+
.to-shortcuts {
1994+
display: inline-block;
1995+
position: fixed;
1996+
top: 92%;
1997+
right: 1%;
1998+
}
1999+
2000+
19802001
/*
19812002
#vstobjects {
19822003
margin-top: -1px;
@@ -2737,6 +2758,7 @@ form#vstobjects.suspended {
27372758
color: #eee;
27382759
width: 800px;
27392760
border: 1px solid #333;
2761+
font-size: 13px;
27402762
}
27412763
.shortcuts .header {
27422764
border-bottom: 1px solid #333;
@@ -2777,7 +2799,7 @@ form#vstobjects.suspended {
27772799
padding: 5px 20px;
27782800
}
27792801
.shortcuts ul li.step-top {
2780-
padding-bottom: 30px;
2802+
padding-top: 30px;
27812803
}
27822804
.shortcuts ul li span {
27832805
color: #48F4EF;

web/edit/file/index.php

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -57,20 +57,24 @@
5757
if ($fn) {
5858
$f = fopen ($fn, 'w+');
5959
fwrite($f, $_POST['contents']);
60+
fclose($f);
61+
62+
chmod($fn, 0644);
63+
6064
if ($f) {
6165
//copy($fn, $path);
6266
exec (VESTA_CMD . "v-copy-fs-file {$user} {$fn} {$path}", $output, $return_var);
6367

6468
$error = check_return_code($return_var, $output);
6569
if ($return_var != 0) {
66-
var_dump(VESTA_CMD . "v-copy-fs-file {$user} {$fn} {$path}");
70+
/*var_dump(VESTA_CMD . "v-copy-fs-file {$user} {$fn} {$path}");
6771
var_dump($path);
68-
var_dump($output);
72+
var_dump($output);*/
6973
die('<p style="color: white">Error while saving file</p>');//echo '0';
7074
}
7175
}
7276
unlink($fn);
73-
}
77+
}
7478
}
7579

7680
// $content = file_get_contents($path);

web/images/sprite.png

540 Bytes
Loading

web/inc/i18n/en.php

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -546,4 +546,54 @@
546546
'Create file' => 'Create file',
547547
'Create directory' => 'Create directory',
548548

549+
550+
'Add New object' => 'Add New object',
551+
'Save Form' => 'Save Form',
552+
'Cancel saving form' => 'Cancel saving form',
553+
'Go to USER list' => 'Go to USER list',
554+
'Go to WEB list' => 'Go to WEB list',
555+
'Go to DNS list' => 'Go to DNS list',
556+
'Go to MAIL list' => 'Go to MAIL list',
557+
'Go to DB list' => 'Go to DB list',
558+
'Go to CRON list' => 'Go to CRON list',
559+
'Go to BACKUP list' => 'Go to BACKUP list',
560+
'Focus on search' => 'Focus on search',
561+
'Display/Close shortcuts' => 'Display/Close shortcuts',
562+
'Go to Packages' => 'Go to Packages',
563+
'Go to IP' => 'Go to IP',
564+
'Go to Graphs' => 'Go to Graphs',
565+
'Go to Statistic' => 'Go to Statistic',
566+
'Go to Log' => 'Go to Log',
567+
'Go to Updates' => 'Go to Updates',
568+
'Go to Firewall' => 'Go to Firewall',
569+
'Go to File Manager' => 'Go to File Manager',
570+
'Go to Server' => 'Go to Server',
571+
572+
573+
'Upload' => 'Upload',
574+
'New File' => 'New File',
575+
'New Folder' => 'New Folder',
576+
'Download' => 'Download',
577+
'Rename' => 'Rename',
578+
'Copy' => 'Copy',
579+
'Archive' => 'Archive',
580+
'Delete' => 'Delete',
581+
'Save File (in text editor)' => 'Save File (in text editor)',
582+
'Display Shortcuts Hel' => 'Display Shortcuts Hel',
583+
'Close Popup / Cancel' => 'Close Popup / Cancel',
584+
'Move Cursor Up' => 'Move Cursor Up',
585+
'Move Cursor Dow' => 'Move Cursor Dow',
586+
'Switch to Left Tab' => 'Switch to Left Tab',
587+
'Switch to Right Tab' => 'Switch to Right Tab',
588+
'Switch Tab' => 'Switch Tab',
589+
'Go to the Top of File List' => 'Go to the Top of File List',
590+
'Go to the Last File' => 'Go to the Last File',
591+
'Open File/Enter Directory' => 'Open File/Enter Directory',
592+
'Go to Parent Directory' => 'Go to Parent Directory',
593+
'Select Current File' => 'Select Current File',
594+
'Select Bunch of Files' => 'Select Bunch of Files',
595+
'Append File to the Current Selection' => 'Append File to the Current Selection',
596+
'Select All Files' => 'Select All Files',
597+
'shortcuts are inspired by magnificent GNU <a href="https://www.midnight-commander.org/">Midnight Commander</a> file manager' => 'shortcuts are inspired by magnificent GNU <a href="https://www.midnight-commander.org/">Midnight Commander</a> file manager',
598+
549599
);

0 commit comments

Comments
 (0)