diff options
author | Arthur Schiwon <blizzz@arthur-schiwon.de> | 2011-04-17 18:14:26 +0200 |
---|---|---|
committer | Arthur Schiwon <blizzz@arthur-schiwon.de> | 2011-04-17 18:14:26 +0200 |
commit | ec7e33870441f81f10385ca0329e7a91fcf3ae45 (patch) | |
tree | 4faa4abe4c22f18bcd114281860563c15266d063 /files | |
parent | d59b0df401c76e7434fda889af81f47adb5bd656 (diff) | |
download | nextcloud-server-ec7e33870441f81f10385ca0329e7a91fcf3ae45.tar.gz nextcloud-server-ec7e33870441f81f10385ca0329e7a91fcf3ae45.zip |
display max file size for upload
Diffstat (limited to 'files')
-rw-r--r-- | files/index.php | 5 | ||||
-rw-r--r-- | files/templates/index.php | 2 |
2 files changed, 5 insertions, 2 deletions
diff --git a/files/index.php b/files/index.php index 28743f77fca..c0f078bd215 100644 --- a/files/index.php +++ b/files/index.php @@ -61,11 +61,14 @@ $list->assign( "files", $files ); $breadcrumbNav = new OC_TEMPLATE( "files", "part.breadcrumb", "" ); $breadcrumbNav->assign( "breadcrumb", $breadcrumb ); +$maxUploadFilesize = OC_HELPER::computerFileSize(ini_get('upload_max_filesize')); + $tmpl = new OC_TEMPLATE( "files", "index", "user" ); $tmpl->assign( "fileList", $list->fetchPage() ); $tmpl->assign( "breadcrumb", $breadcrumbNav->fetchPage() ); $tmpl->assign( 'dir', $dir); -$tmpl->assign( 'uploadMaxFilesize', OC_HELPER::computerFileSize(ini_get('upload_max_filesize'))); +$tmpl->assign( 'uploadMaxFilesize', $maxUploadFilesize); +$tmpl->assign( 'uploadMaxHumanFilesize', OC_HELPER::humanFileSize($maxUploadFilesize)); $tmpl->printPage(); ?> diff --git a/files/templates/index.php b/files/templates/index.php index c6dc123cee0..b556da5513d 100644 --- a/files/templates/index.php +++ b/files/templates/index.php @@ -11,7 +11,7 @@ method="post" enctype="multipart/form-data" target="file_upload_target"><input type="hidden" name="MAX_FILE_SIZE" value="<?php echo $_["uploadMaxFilesize"] ?>" id="max_upload"><input type="hidden" name="dir" value="<?php echo $_["dir"] ?>" id="dir"><input type="file" name="file" id="fileSelector"><input type="submit" -id="file_upload_start" value="Upload" /><iframe id="file_upload_target" +id="file_upload_start" value="Upload (max <?php echo $_["uploadMaxHumanFilesize"];?>)" /><iframe id="file_upload_target" name="file_upload_target" src=""></iframe></form> <form id="file_newfolder_form"><input type="text" name="file_new_dir_name" id="file_new_dir_name" /> <input type="button" id="file_new_dir_submit" name="file_new_dir_submit" value="OK" /></form> </div> |