aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSilvio Rhatto <rhatto@riseup.net>2021-04-08 21:55:14 -0300
committerSilvio Rhatto <rhatto@riseup.net>2021-04-08 21:55:14 -0300
commitdd5335583618235ec9df212f0c3a80277955dc7d (patch)
treea377223ba3bd18255f0331f89abf4ef75606a68b
parent7645875214b7cc60016e44d9b218699a193c60e4 (diff)
downloadsemanticscuttle-dd5335583618235ec9df212f0c3a80277955dc7d.tar.gz
semanticscuttle-dd5335583618235ec9df212f0c3a80277955dc7d.tar.bz2
Fix: try to fix bookmark import size limit
-rw-r--r--data/templates/default/importNetscape.tpl.php4
-rw-r--r--puppet/config/node/links.example.org.yaml14
-rw-r--r--www/importNetscape.php4
3 files changed, 20 insertions, 2 deletions
diff --git a/data/templates/default/importNetscape.tpl.php b/data/templates/default/importNetscape.tpl.php
index 627a5af..7ed4bb1 100644
--- a/data/templates/default/importNetscape.tpl.php
+++ b/data/templates/default/importNetscape.tpl.php
@@ -8,7 +8,7 @@ $this->includeTemplate($GLOBALS['top_include']);
<tr valign="top">
<th align="left"><?php echo T_('File'); ?></th>
<td>
- <input type="hidden" name="MAX_FILE_SIZE" value="1024000" />
+ <input type="hidden" name="MAX_FILE_SIZE" value="104857600" />
<input type="file" name="userfile" size="50" />
</td>
</tr>
@@ -47,4 +47,4 @@ $this->includeTemplate($GLOBALS['top_include']);
<?php
$this->includeTemplate($GLOBALS['bottom_include']);
-?> \ No newline at end of file
+?>
diff --git a/puppet/config/node/links.example.org.yaml b/puppet/config/node/links.example.org.yaml
index 449feff..9041cbf 100644
--- a/puppet/config/node/links.example.org.yaml
+++ b/puppet/config/node/links.example.org.yaml
@@ -11,6 +11,20 @@ classes:
- 'php'
#
+# PHP
+#
+php::config:
+ #post_max_size:
+ # series: '7'
+ # value: '100M'
+ #upload_max_filesize:
+ # series: '7'
+ # value: '100M'
+ memory_limit:
+ series: '7'
+ value: '128M'
+
+#
# MySQL
#
mysql::server::implementation: 'mariadb-server'
diff --git a/www/importNetscape.php b/www/importNetscape.php
index 9a52407..909305d 100644
--- a/www/importNetscape.php
+++ b/www/importNetscape.php
@@ -33,6 +33,10 @@ isset($_POST['status']) ? define('POST_STATUS', $_POST['status']): define('POST_
$countImportedBookmarks = 0;
$tplVars['msg'] = '';
+if ($userservice->isLoggedOn() && sizeof($_FILES)) {
+print_r($_FILES['userfile']);
+}
+
if ($userservice->isLoggedOn() && sizeof($_FILES) > 0 && $_FILES['userfile']['size'] > 0) {
$userinfo = $userservice->getCurrentObjectUser();