From feba1a41d643b2dd5d946ae4344e1f20cde2567a Mon Sep 17 00:00:00 2001 From: philippe_mingo Date: Thu, 31 Jan 2002 14:14:03 +0000 Subject: [PATCH] Added default string values. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@2320 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- plugins/administrator/defines.php | 3 ++- plugins/administrator/options.php | 4 ++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/administrator/defines.php b/plugins/administrator/defines.php index b405a840..f61d3769 100644 --- a/plugins/administrator/defines.php +++ b/plugins/administrator/defines.php @@ -67,7 +67,8 @@ $defcfg = array( '$config_version' => array( 'name' => _("Config File Version"), 'posvals' => $language_values ), '$frame_top' => array( 'name' => _("Top Frame"), 'type' => SMOPT_TYPE_STRING, - 'size' => 40 ), + 'size' => 40, + 'default' => '_top' ), /* --------------------------------------------------------*/ 'Group2' => array( 'name' => _("Server Settings"), 'type' => SMOPT_TYPE_TITLE ), diff --git a/plugins/administrator/options.php b/plugins/administrator/options.php index 3d045bec..2bab41ce 100644 --- a/plugins/administrator/options.php +++ b/plugins/administrator/options.php @@ -311,6 +311,10 @@ foreach ( $newcfg as $k => $v ) { $v = '"' . $HTTP_POST_VARS[$e] . '"'; $newcfg[$k] = $v; } + if ( $v == '""' && isset( $defcfg[$k]['default'] ) ) { + $v = "'" . $defcfg[$k]['default'] . "'"; + $newcfg[$k] = $v; + } echo "$name". ""; if ( isset( $defcfg[$k]['comment'] ) ) { -- 2.25.1