X-Git-Url: https://git.p6c8.net/devedit.git/blobdiff_plain/c1bfe3c380707e7cc6b0582b63f31a77d6f8751a..cbd1dfad21c6f2868a40a1869fb32f3f2740c07a:/modules/Command.pm?ds=sidebyside diff --git a/modules/Command.pm b/modules/Command.pm index e06d0b6..8ffc765 100644 --- a/modules/Command.pm +++ b/modules/Command.pm @@ -6,7 +6,7 @@ package Command; # Execute Dev-Editor's commands # # Author: Patrick Canterino -# Last modified: 2005-01-20 +# Last modified: 2005-01-24 # use strict; @@ -126,9 +126,7 @@ sub exec_show($$) $udtpl->read_file($config->{'templates'}->{'dirlist_up'}); $udtpl->fillin('UPPER_DIR',$upper_path); - $udtpl->fillin('DATE',encode_entities(strftime($config->{'timeformat'},localtime($stat[9])))); - - $udtpl->parse_if_block('gmt',$config->{'use_gmt'}); + $udtpl->fillin('DATE',encode_entities(strftime($config->{'timeformat'},($config->{'use_gmt'}) ? gmtime($stat[9]) : localtime($stat[9])))); $dirlist .= $udtpl->get_template; } @@ -155,8 +153,6 @@ sub exec_show($$) $dtpl->parse_if_block('readable',-r $phys_path && -x $phys_path); $dtpl->parse_if_block('users',$users && -o $phys_path); - $dtpl->parse_if_block('gmt',$config->{'use_gmt'}); - $dirlist .= $dtpl->get_template; } @@ -194,8 +190,6 @@ sub exec_show($$) $ftpl->parse_if_block('too_large',$config->{'max_file_size'} && $stat[7] > $config->{'max_file_size'}); - $ftpl->parse_if_block('gmt',$config->{'use_gmt'}); - $ftpl->parse_if_block('users',$users && -o $phys_path); $dirlist .= $ftpl->get_template; @@ -213,6 +207,7 @@ sub exec_show($$) $tpl->parse_if_block('dir_writeable',$dir_writeable); $tpl->parse_if_block('filter',$filter2); + $tpl->parse_if_block('gmt',$config->{'use_gmt'}); } else { @@ -379,7 +374,7 @@ sub exec_endedit($$) if(file_save($physical,\$content)) { - # Saving of the file was successful! + # The file was successfully saved! return devedit_reload({command => 'show', file => $dir}); } @@ -469,7 +464,7 @@ sub exec_mkdir($$) # exec_upload() # -# Upload a file +# Process a file upload # # Params: 1. Reference to user input hash # 2. Reference to config hash @@ -926,7 +921,8 @@ sub exec_about($$) $tpl->fillin('PID',$$); - # Check if the functions getpwuid() and getgrgid() are available + # The following information is only available on systems supporting + # users and groups if($users) {