summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoakim Reinert <mail@jreinert.com>2015-05-01 23:18:48 +0200
committerFlorian Pritz <bluewind@xinu.at>2015-05-05 12:21:27 +0200
commitb76a85e2992000bd6fa21a58050ffcac0f8fba39 (patch)
tree418911d808057577148c61f199e222deb7715c92
parent9466b2f5e3b50fd625f0de26bbc37b8a35206704 (diff)
Set max upload size and file count in upload_form view only
-rw-r--r--application/views/file/upload_form.php4
-rw-r--r--application/views/header.php5
2 files changed, 3 insertions, 6 deletions
diff --git a/application/views/file/upload_form.php b/application/views/file/upload_form.php
index f9f40475d..8fc7b9f59 100644
--- a/application/views/file/upload_form.php
+++ b/application/views/file/upload_form.php
@@ -70,8 +70,8 @@
<script type="text/javascript">
/* <![CDATA[ */
- var max_upload_size = "<?php echo $max_upload_size; ?>";
- var max_files_per_upload = "<?php echo ini_get("max_file_uploads"); ?>";
+ window.appConfig.maxUploadSize = "<?php echo $max_upload_size; ?>";
+ window.appConfig.maxFilesPerUpload = "<?php echo ini_get("max_file_uploads"); ?>";
/* ]]> */
</script>
diff --git a/application/views/header.php b/application/views/header.php
index f77487ba9..89a3c8617 100644
--- a/application/views/header.php
+++ b/application/views/header.php
@@ -29,10 +29,7 @@ if (is_cli_client() && !isset($force_full_html)) {
<script type="text/javascript">
/* <![CDATA[ */
var require = { baseUrl: '/data/js' };
- window.appConfig = {
- maxUploadSize: <?php echo $max_upload_size; ?>,
- maxFilesPerUpload: <?php echo ini_get("max_file_uploads"); ?>
- };
+ window.appConfig = {};
/* ]]> */
</script>
<script data-main="main" src="/data/js/vendor/require.js"></script>