Aleksander Machniak
2013-06-14 70ef48c2f311f1773a4b4deb8fcffd8ea72326f9
installer/config.php
@@ -1,3 +1,10 @@
<?php
if (!class_exists('rcube_install') || !is_object($RCI)) {
    die("Not allowed! Please open installer/index.php instead.");
}
?>
<form action="index.php" method="post">
<input type="hidden" name="_step" value="2" />
<?php
@@ -8,7 +15,6 @@
// register these boolean fields
$RCI->bool_config_props = array(
  'ip_check' => 1,
  'enable_caching' => 1,
  'enable_spellcheck' => 1,
  'auto_create_user' => 1,
  'smtp_log' => 1,
@@ -59,6 +65,30 @@
<div>The name of your service (used to compose page titles)</div>
</dd>
<dt class="propname">support_url</dt>
<dd>
<?php
$input_support = new html_inputfield(array('name' => '_support_url', 'size' => 50, 'id' => "cfgsupporturl"));
echo $input_support->show($RCI->getprop('support_url'));
?>
<div>Provide an URL where a user can get support for this Roundcube installation.<br/>PLEASE DO NOT LINK TO THE ROUNDCUBE.NET WEBSITE HERE!</div>
<p class="hint">Enter an absolute URL (inculding http://) to a support page/form or a mailto: link.</p>
</dd>
<dt class="propname">skin_logo</dt>
<dd>
<?php
$input_skin = new html_inputfield(array('name' => '_skin_logo', 'size' => 50, 'id' => "cfgskinlogo"));
echo $input_skin->show($RCI->getprop('skin_logo'));
?>
<div>Custom image to display instead of the Roundcube logo.</div>
<p class="hint">Enter a URL relative to the document root of this Roundcube installation.</p>
</dd>
<dt class="propname">temp_dir</dt>
<dd>
<?php
@@ -70,6 +100,18 @@
<div>Use this folder to store temp files (must be writeable for webserver)</div>
</dd>
<dt class="propname">des_key</dt>
<dd>
<?php
$input_deskey = new html_inputfield(array('name' => '_des_key', 'size' => 30, 'id' => "cfgdeskey"));
echo $input_deskey->show($RCI->getprop('des_key'));
?>
<div>This key is used to encrypt the users imap password before storing in the session record</div>
<p class="hint">It's a random generated string to ensure that every installation has its own key.
If you enter it manually please provide a string of exactly 24 chars.</p>
</dd>
<dt class="propname">ip_check</dt>
<dd>
@@ -81,32 +123,9 @@
?>
<label for="cfgipcheck">Check client IP in session authorization</label><br />
<p class="hint">This increases security but can cause sudden logouts when someone uses a proxy with changeing IPs.</p>
<p class="hint">This increases security but can cause sudden logouts when someone uses a proxy with changing IPs.</p>
</dd>
<dt class="propname">des_key</dt>
<dd>
<?php
$input_deskey = new html_inputfield(array('name' => '_des_key', 'size' => 30, 'id' => "cfgdeskey"));
echo $input_deskey->show($RCI->getprop('des_key'));
?>
<div>This key is used to encrypt the users imap password before storing in the session record</div>
<p class="hint">It's a random generated string to ensure that every installation has it's own key.
If you enter it manually please provide a string of exactly 24 chars.</p>
</dd>
<dt class="propname">enable_caching</dt>
<dd>
<?php
$check_caching = new html_checkbox(array('name' => '_enable_caching', 'id' => "cfgcache"));
echo $check_caching->show(intval($RCI->getprop('enable_caching')), array('value' => 1));
?>
<label for="cfgcache">Cache messages in local database</label><br />
</dd>
<dt class="propname">enable_spellcheck</dt>
<dd>
@@ -244,15 +263,10 @@
<p>Database settings for read/write operations:</p>
<?php
require_once 'MDB2.php';
$supported_dbs = array('MySQL' => 'mysql', 'MySQLi' => 'mysqli',
    'PgSQL' => 'pgsql', 'SQLite' => 'sqlite');
$select_dbtype = new html_select(array('name' => '_dbtype', 'id' => "cfgdbtype"));
foreach ($supported_dbs AS $database => $ext) {
foreach ($RCI->supported_dbs as $database => $ext) {
    if (extension_loaded($ext)) {
        $select_dbtype->add($database, $ext);
        $select_dbtype->add($database, substr($ext, 4));
    }
}
@@ -261,7 +275,7 @@
$input_dbuser = new html_inputfield(array('name' => '_dbuser', 'size' => 20, 'id' => "cfgdbuser"));
$input_dbpass = new html_passwordfield(array('name' => '_dbpass', 'size' => 20, 'id' => "cfgdbpass"));
$dsnw = MDB2::parseDSN($RCI->getprop('db_dsnw'));
$dsnw = rcube_db::parse_dsn($RCI->getprop('db_dsnw'));
echo $select_dbtype->show($RCI->is_post ? $_POST['_dbtype'] : $dsnw['phptype']);
echo '<label for="cfgdbtype">Database type</label><br />';
@@ -361,7 +375,7 @@
?>
<div>Store sent messages in this folder</div>
<p class="hint">Leave blank if sent messages should not be stored</p>
<p class="hint">Leave blank if sent messages should not be stored. Note: folder must include namespace prefix if any.</p>
</dd>
<dt class="propname">trash_mbox</dt>
@@ -374,7 +388,7 @@
?>
<div>Move messages to this folder when deleting them</div>
<p class="hint">Leave blank if they should be deleted directly</p>
<p class="hint">Leave blank if they should be deleted directly. Note: folder must include namespace prefix if any.</p>
</dd>
<dt class="propname">drafts_mbox</dt>
@@ -387,7 +401,7 @@
?>
<div>Store draft messages in this folder</div>
<p class="hint">Leave blank if they should not be stored</p>
<p class="hint">Leave blank if they should not be stored. Note: folder must include namespace prefix if any.</p>
</dd>
<dt class="propname">junk_mbox</dt>
@@ -399,6 +413,10 @@
?>
<div>Store spam messages in this folder</div>
<p class="hint">Note: folder must include namespace prefix if any.</p>
</dd>
</dd>
</dl>
</fieldset>
@@ -508,27 +526,34 @@
<div>Name of interface skin (folder in /skins)</div>
</dd>
<dt class="propname">skin_logo</dt>
<dt class="propname">mail_pagesize <span class="userconf">*</span></dt>
<dd>
<?php
$input_skin = new html_inputfield(array('name' => '_skin_logo', 'size' => 50, 'id' => "cfgskinlogo"));
echo $input_skin->show($RCI->getprop('skin_logo'));
$pagesize = $RCI->getprop('mail_pagesize');
if (!$pagesize) {
    $pagesize = $RCI->getprop('pagesize');
}
$input_pagesize = new html_inputfield(array('name' => '_mail_pagesize', 'size' => 6, 'id' => "cfgmailpagesize"));
echo $input_pagesize->show($pagesize);
?>
<div>Custom image to display instead of the Roundcube logo.</div>
<p class="hint">Enter a URL relative to the document root of this Roundcube installation.</p>
<div>Show up to X items in the mail messages list view.</div>
</dd>
<dt class="propname">pagesize <span class="userconf">*</span></dt>
<dt class="propname">addressbook_pagesize <span class="userconf">*</span></dt>
<dd>
<?php
$input_pagesize = new html_inputfield(array('name' => '_pagesize', 'size' => 6, 'id' => "cfgpagesize"));
echo $input_pagesize->show($RCI->getprop('pagesize'));
$pagesize = $RCI->getprop('addressbook_pagesize');
if (!$pagesize) {
    $pagesize = $RCI->getprop('pagesize');
}
$input_pagesize = new html_inputfield(array('name' => '_addressbook_pagesize', 'size' => 6, 'id' => "cfgabookpagesize"));
echo $input_pagesize->show($pagesize);
?>
<div>Show up to X items in list view.</div>
<div>Show up to X items in the contacts list view.</div>
</dd>
<dt class="propname">prefer_html <span class="userconf">*</span></dt>