diff options
| author | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2008-02-28 22:59:02 +0000 |
|---|---|---|
| committer | thomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2008-02-28 22:59:02 +0000 |
| commit | dcf21363a62c8f661e5e67baa0c6ffbed02cf263 (patch) | |
| tree | 3b30d874f439dd7e0f1b6a1ba57418154a9f414b /roundcubemail/installer/rcube_install.php | |
| parent | 9cf8668eb789a66539ee470aafb52d1b7740ba2e (diff) | |
Fix imap host selection in install script
git-svn-id: https://svn.roundcube.net/trunk@1158 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/installer/rcube_install.php')
| -rw-r--r-- | roundcubemail/installer/rcube_install.php | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/roundcubemail/installer/rcube_install.php b/roundcubemail/installer/rcube_install.php index e02ee75ad..35054a19e 100644 --- a/roundcubemail/installer/rcube_install.php +++ b/roundcubemail/installer/rcube_install.php @@ -98,7 +98,8 @@ class rcube_install */ function getprop($name, $default = '') { - $value = $_SERVER['REQUEST_METHOD'] == 'POST' ? $_POST["_$name"] : $this->config[$name]; + $value = $_SERVER['REQUEST_METHOD'] == 'POST' && + (isset($_POST["_$name"]) || $this->config_props[$name]) ? $_POST["_$name"] : $this->config[$name]; if ($name == 'des_key' && !isset($_REQUEST["_$name"])) $value = self::random_key(24); @@ -182,6 +183,25 @@ class rcube_install /** + * Return a list with all imap hosts configured + * + * @return array Clean list with imap hosts + */ + function get_hostlist() + { + $default_hosts = (array)$this->getprop('default_host'); + $out = array(); + + foreach ($default_hosts as $key => $name) { + if (!empty($name)) + $out[] = is_numeric($key) ? $name : $key; + } + + return $out; + } + + + /** * Display OK status * * @param string Test name |
