Added newmail dropdowns, and preparing for special folders only count mails.
[squirrelmail.git] / plugins / administrator / defines.php
CommitLineData
abd7a3f8 1<?PHP
2
3/**
4 * defines.php
5 *
6 * Copyright (c) 1999-2002 The SquirrelMail Project Team
7 * Licensed under the GNU GPL. For full terms see the file COPYING.
8 *
9 * Philippe Mingo
10 *
11 * $Id$
12 */
13
5ed13ec8 14require_once( '../functions/constants.php' );
abd7a3f8 15
16/* Define constants for the various option types. */
17define('SMOPT_TYPE_UNDEFINED', -1);
18define('SMOPT_TYPE_STRING', 0);
19define('SMOPT_TYPE_STRLIST', 1);
20define('SMOPT_TYPE_TEXTAREA', 2);
21define('SMOPT_TYPE_INTEGER', 3);
22define('SMOPT_TYPE_FLOAT', 4);
23define('SMOPT_TYPE_BOOLEAN', 5);
24define('SMOPT_TYPE_HIDDEN', 6);
25define('SMOPT_TYPE_COMMENT', 7);
dcd6f144 26define('SMOPT_TYPE_NUMLIST', 8);
edd4a552 27define('SMOPT_TYPE_TITLE', 9);
28define('SMOPT_TYPE_THEME', 10);
29define('SMOPT_TYPE_PLUGINS', 11);
65a5bae6 30define('SMOPT_TYPE_LDAP', 12);
abd7a3f8 31
32global $languages;
33
35be4418 34$language_values = array( );
abd7a3f8 35foreach ($languages as $lang_key => $lang_attributes) {
36 if (isset($lang_attributes['NAME'])) {
37 $language_values[$lang_key] = $lang_attributes['NAME'];
38 }
39}
40asort( $language_values );
35be4418 41$language_values = array_merge(array('' => _("Default")), $language_values);
dcd6f144 42$left_size_values = array();
43for ($lsv = 100; $lsv <= 300; $lsv += 10) {
44 $left_size_values[$lsv] = "$lsv " . _("pixels");
45}
46
0e66bc84 47$defcfg = array( '$config_version' => array( 'name' => _("Config File Version"),
48 'type' => SMOPT_TYPE_COMMENT,
abd7a3f8 49 'size' => 7 ),
0e66bc84 50 /* --------------------------------------------------------*/
51 'Group1' => array( 'name' => _("Organization Preferences"),
52 'type' => SMOPT_TYPE_TITLE ),
53 '$org_name' => array( 'name' => _("Organization Name"),
abd7a3f8 54 'type' => SMOPT_TYPE_STRING,
55 'size' => 40 ),
0e66bc84 56 '$org_logo' => array( 'name' => _("Organization Logo"),
abd7a3f8 57 'type' => SMOPT_TYPE_STRING,
58 'size' => 40 ),
0e66bc84 59 '$org_title' => array( 'name' => _("Organization Title"),
abd7a3f8 60 'type' => SMOPT_TYPE_STRING,
61 'size' => 40 ),
0e66bc84 62 '$signout_page' => array( 'name' => _("Signout Page"),
63 'type' => SMOPT_TYPE_STRING,
64 'size' => 40 ),
abd7a3f8 65 '$squirrelmail_default_language' => array( 'name' => _("Default Language"),
66 'type' => SMOPT_TYPE_STRLIST,
67 'size' => 7,
68 'posvals' => $language_values ),
dcd6f144 69 '$frame_top' => array( 'name' => _("Top Frame"),
70 'type' => SMOPT_TYPE_STRING,
feba1a41 71 'size' => 40,
72 'default' => '_top' ),
0e66bc84 73 /* --------------------------------------------------------*/
74 'Group2' => array( 'name' => _("Server Settings"),
75 'type' => SMOPT_TYPE_TITLE ),
76 '$domain' => array( 'name' => _("Mail Domain"),
77 'type' => SMOPT_TYPE_STRING,
78 'size' => 40 ),
abd7a3f8 79 '$imapServerAddress' => array( 'name' => _("IMAP Server Address"),
80 'type' => SMOPT_TYPE_STRING,
81 'size' => 40 ),
82 '$imapPort' => array( 'name' => _("IMAP Server Port"),
83 'type' => SMOPT_TYPE_INTEGER ),
0e66bc84 84 '$imap_server_type' => array( 'name' => _("IMAP Server Type"),
85 'type' => SMOPT_TYPE_STRLIST,
0e66bc84 86 'posvals' => array( 'cyrus' => _("Cyrus IMAP server"),
87 'uw' => _("University of Washington's IMAP server"),
88 'exchange' => _("Microsoft Exchange IMAP server"),
89 'courier' => _("Courier IMAP server"),
90 'other' => _("Not one of the above servers") ) ),
91 '$optional_delimiter' => array( 'name' => _("IMAP Folder Delimiter"),
92 'type' => SMOPT_TYPE_STRING,
edd4a552 93 'comment' => _("Use \"detect\" to auto-detect."),
2586d588 94 'size' => 10,
95 'default' => 'detect' ),
0e66bc84 96 '$useSendmail' => array( 'name' => _("Use Sendmail"),
97 'type' => SMOPT_TYPE_BOOLEAN ),
dcd6f144 98 '$sendmail_path' => array( 'name' => _("Sendmail Path"),
99 'type' => SMOPT_TYPE_STRING,
100 'size' => 40 ),
abd7a3f8 101 '$smtpServerAddress' => array( 'name' => _("SMTP Server Address"),
102 'type' => SMOPT_TYPE_STRING,
103 'size' => 40 ),
104 '$smtpPort' => array( 'name' => _("SMTP Server Port"),
105 'type' => SMOPT_TYPE_INTEGER ),
0e66bc84 106 '$use_authenticated_smtp' => array( 'name' => _("Authenticated SMTP"),
107 'type' => SMOPT_TYPE_BOOLEAN ),
108 '$invert_time' => array( 'name' => _("Invert Time"),
109 'type' => SMOPT_TYPE_BOOLEAN ),
110 /* --------------------------------------------------------*/
111 'Group3' => array( 'name' => _("Folders Defaults"),
112 'type' => SMOPT_TYPE_TITLE ),
dcd6f144 113 '$default_folder_prefix' => array( 'name' => _("Default Folder Prefix"),
114 'type' => SMOPT_TYPE_STRING,
115 'size' => 40 ),
116 '$show_prefix_option' => array( 'name' => _("Show Folder Prefix Option"),
117 'type' => SMOPT_TYPE_BOOLEAN ),
118 '$trash_folder' => array( 'name' => _("Trash Folder"),
119 'type' => SMOPT_TYPE_STRING,
120 'size' => 40 ),
121 '$sent_folder' => array( 'name' => _("Sent Folder"),
122 'type' => SMOPT_TYPE_STRING,
123 'size' => 40 ),
124 '$draft_folder' => array( 'name' => _("Draft Folder"),
125 'type' => SMOPT_TYPE_STRING,
126 'size' => 40 ),
127 '$default_move_to_trash' => array( 'name' => _("By default, move to trash"),
128 'type' => SMOPT_TYPE_BOOLEAN ),
129 '$default_move_to_sent' => array( 'name' => _("By default, move to sent"),
130 'type' => SMOPT_TYPE_BOOLEAN ),
131 '$default_save_as_draft' => array( 'name' => _("By default, save as draft"),
132 'type' => SMOPT_TYPE_BOOLEAN ),
133 '$list_special_folders_first' => array( 'name' => _("List Special Folders First"),
134 'type' => SMOPT_TYPE_BOOLEAN ),
135 '$use_special_folder_color' => array( 'name' => _("Show Special Folders Color"),
136 'type' => SMOPT_TYPE_BOOLEAN ),
137 '$auto_expunge' => array( 'name' => _("Auto Expunge"),
138 'type' => SMOPT_TYPE_BOOLEAN ),
139 '$default_sub_of_inbox' => array( 'name' => _("Default Sub. of INBOX"),
140 'type' => SMOPT_TYPE_BOOLEAN ),
141 '$show_contain_subfolders_option' => array( 'name' => _("Show 'Contain Sub.' Option"),
142 'type' => SMOPT_TYPE_BOOLEAN ),
143 '$default_unseen_notify' => array( 'name' => _("Default Unseen Notify"),
5ed13ec8 144 'type' => SMOPT_TYPE_NUMLIST,
145 'posvals' => array( SMPREF_UNSEEN_NONE => _("No Notification"),
146 SMPREF_UNSEEN_INBOX => _("Only INBOX"),
147 SMPREF_UNSEEN_ALL => _("All Folders")) ),
dcd6f144 148 '$default_unseen_type' => array( 'name' => _("Default Unseen Type"),
5ed13ec8 149 'type' => SMOPT_TYPE_NUMLIST ,
150 'posvals' => array( SMPREF_UNSEEN_ONLY => _("Only Unseen"),
151 SMPREF_UNSEEN_TOTAL => _("Unseen and Total") ) ),
dcd6f144 152 '$auto_create_special' => array( 'name' => _("Auto Create Special Folders"),
153 'type' => SMOPT_TYPE_BOOLEAN ),
e91cf665 154 '$default_use_javascript_addr_book' => array( 'name' => _("Default Javascript Adrressbook"),
155 'type' => SMOPT_TYPE_BOOLEAN ),
dcd6f144 156 /* --------------------------------------------------------*/
d0102e1a 157 'Group4' => array( 'name' => _("General Options"),
dcd6f144 158 'type' => SMOPT_TYPE_TITLE ),
159 '$default_charset' => array( 'name' => _("Default Charset"),
edd4a552 160 'type' => SMOPT_TYPE_STRLIST,
161 'posvals' => array( 'iso_8859_1' => 'iso_8859_1',
162 'iso_8859_2' => 'iso_8859_2',
163 'iso_8859_7' => 'iso_8859_7',
164 'iso_8859_15' => 'iso_8859_15',
165 'iso_8859_15' => 'iso_8859_15',
166 'ns_4551_1' => 'ns_4551_1',
167 'koi8-r' => 'koi8-r',
168 'euc-KR' => 'euc-KR',
169 'windows-1251' => 'windows-1251' ) ),
dcd6f144 170 '$data_dir' => array( 'name' => _("Data Directory"),
171 'type' => SMOPT_TYPE_STRING,
172 'size' => 40 ),
173 '$attachment_dir' => array( 'name' => _("Temp Directory"),
abd7a3f8 174 'type' => SMOPT_TYPE_STRING,
175 'size' => 40 ),
dcd6f144 176 '$dir_hash_level' => array( 'name' => _("Hash Level"),
177 'type' => SMOPT_TYPE_NUMLIST,
178 'posvals' => array( 0 => _("Hash Disabled"),
179 1 => _("Low"),
180 2 => _("Moderate"),
181 3 => _("Medium"),
182 4 => _("High") ) ),
edd4a552 183 '$default_left_size' => array( 'name' => _("Default Left Size"),
dcd6f144 184 'type' => SMOPT_TYPE_NUMLIST,
185 'posvals' => $left_size_values ),
186 '$force_username_lowercase' => array( 'name' => _("Usernames in Lowercase"),
187 'type' => SMOPT_TYPE_BOOLEAN ),
188 '$default_use_priority' => array( 'name' => _("Allow use of priority"),
189 'type' => SMOPT_TYPE_BOOLEAN ),
190 '$hide_sm_attributions' => array( 'name' => _("Hide SM attributions"),
191 'type' => SMOPT_TYPE_BOOLEAN ),
192 /* --------------------------------------------------------*/
edd4a552 193 'Group5' => array( 'name' => _("Message of the Day"),
194 'type' => SMOPT_TYPE_TITLE ),
195 '$motd' => array( 'name' => _("Message of the Day"),
196 'type' => SMOPT_TYPE_TEXTAREA,
197 'size' => 40 ),
198 /* --------------------------------------------------------*/
497203d4 199 'Group6' => array( 'name' => _("Database"),
200 'type' => SMOPT_TYPE_TITLE ),
201 '$addrbook_dsn' => array( 'name' => _("Address book DSN"),
202 'type' => SMOPT_TYPE_STRING,
203 'size' => 40 ),
4f40a59d 204 '$addrbook_table' => array( 'name' => _("Address book table"),
205 'type' => SMOPT_TYPE_STRING,
2586d588 206 'size' => 40,
207 'default' => 'address' ),
497203d4 208 /* --------------------------------------------------------*/
209 'Group7' => array( 'name' => _("Themes"),
edd4a552 210 'type' => SMOPT_TYPE_TITLE ),
211 '$theme_css' => array( 'name' => _("Style Sheet URL (css)"),
212 'type' => SMOPT_TYPE_STRING,
213 'size' => 40 ),
214 /* --------------------------------------------------------*/
215 '$config_use_color' => array( 'type' => SMOPT_TYPE_HIDDEN )
497203d4 216 /* --------------------------------------------------------*/
dcd6f144 217
edd4a552 218 );
dcd6f144 219
4f40a59d 220?>