summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoralecpl <alec@alec.pl>2009-05-22 18:34:50 +0000
committeralecpl <alec@alec.pl>2009-05-22 18:34:50 +0000
commit569654a8c350de5b34cb65ae561bf95418b15f1c (patch)
treea582d5a99b41919af5775393d72d49502e83401b
parentaa320ede4b10288542e449bf89bdc8537ee1b6db (diff)
- overwrite default_imap_folders according to *_mbox settings (#1485600) + some small updates
-rw-r--r--installer/config.php4
-rw-r--r--installer/rcube_install.php12
2 files changed, 14 insertions, 2 deletions
diff --git a/installer/config.php b/installer/config.php
index d090312ed..e51b4bf0a 100644
--- a/installer/config.php
+++ b/installer/config.php
@@ -485,7 +485,7 @@ echo $check_smtplog->show(intval($RCI->getprop('smtp_log')), array('value' => 1)
<legend>Display settings &amp; user prefs</legend>
<dl class="configblock" id="cgfblockdisplay">
-<dt class="propname">language</dt>
+<dt class="propname">language <span class="userconf">*</span></dt>
<dd>
<?php
@@ -559,7 +559,7 @@ echo $check_htmlcomp->show(intval($RCI->getprop('htmleditor')));
$select_autosave = new html_select(array('name' => '_draft_autosave', 'id' => 'cfgautosave'));
$select_autosave->add('never', 0);
-foreach (array(3, 5, 10) as $i => $min)
+foreach (array(1, 3, 5, 10) as $i => $min)
$select_autosave->add("$min min", $min*60);
echo $select_autosave->show(intval($RCI->getprop('draft_autosave')));
diff --git a/installer/rcube_install.php b/installer/rcube_install.php
index 14fe5ee47..89ebe9d89 100644
--- a/installer/rcube_install.php
+++ b/installer/rcube_install.php
@@ -176,6 +176,18 @@ class rcube_install
else if ($prop == 'smtp_pass' && !empty($_POST['_smtp_user_u'])) {
$value = '%p';
}
+ else if ($prop == 'default_imap_folders'){
+ $value = Array();
+ foreach($this->config['default_imap_folders'] as $_folder){
+ switch($_folder) {
+ case 'Drafts': $_folder = $this->config['drafts_mbox']; break;
+ case 'Sent': $_folder = $this->config['sent_mbox']; break;
+ case 'Junk': $_folder = $this->config['junk_mbox']; break;
+ case 'Trash': $_folder = $this->config['trash_mbox']; break;
+ }
+ if (!in_array($_folder, $value)) $value[] = $_folder;
+ }
+ }
else if (is_bool($default)) {
$value = (bool)$value;
}