5 ** Copyright (c) 1999-2000 The SquirrelMail development team
6 ** Licensed under the GNU GPL. For full terms see the file COPYING.
8 ** Displays all optinos about display preferences
13 include('../src/validate.php');
14 include('../functions/display_messages.php');
15 include('../functions/imap.php');
16 include('../functions/array.php');
17 include('../functions/plugin.php');
19 displayPageHeader($color, 'None');
20 $chosen_language = getPref($data_dir, $username, 'language');
23 <table width
="95%" align
="center" border
="0" cellpadding
="2" cellspacing
="0">
24 <tr
><td bgcolor
="<?php echo $color[0] ?>" align
="center">
26 <b
><?php
echo _("Options") . ' - ' . _("Display Preferences"); ?
></b
><br
>
28 <table width
="100%" border
="0" cellpadding
="1" cellspacing
="1">
29 <tr
><td bgcolor
="<?php echo $color[4] ?>" align
="center">
31 <form name
="f" action
="options.php" method
="post"><br
>
32 <table width
="100%" cellpadding
="2" cellspacing
="0" border
="0">
34 <td align
="right" nowrap
><?php
echo _("Theme"); ?
>:
37 echo ' <tt><select name="chosentheme">' . "\n";
38 for ($i = 0; $i < count($theme); $i++
) {
39 if ($theme[$i]['PATH'] == $chosen_theme)
40 echo ' <option selected value="'.$theme[$i]['PATH'].'">'.$theme[$i]['NAME']."\n";
42 echo ' <option value="'.$theme[$i]['PATH'].'">'.$theme[$i]['NAME']."\n";
44 echo ' </select></tt>';
49 <td align
="right" nowrap
><?php
echo _("Language"); ?
>:
52 echo ' <tt><select name="language">' . "\n";
53 foreach ($languages as $code => $name) {
54 if ($code==$chosen_language)
55 echo ' <OPTION SELECTED VALUE="'.$code.'">'.$languages[$code]['NAME']."\n";
57 echo ' <OPTION VALUE="'.$code.'">'.$languages[$code]['NAME']."\n";
59 echo ' </select></tt>';
61 echo '<br><small>This system doesn\'t support multiple languages</small>';
66 <td align
=right nowrap
> 
;
67 <?php
echo _("Use Javascript or HTML addressbook?") . '</td><td>';
68 if ($use_javascript_addr_book == true) {
69 echo ' <input type="radio" name="javascript_abook" value="1" checked> ' . _("JavaScript") . ' ';
70 echo ' <input type="radio" name="javascript_abook" value="0"> ' . _("HTML");
72 echo ' <input type="radio" name="javascript_abook" value="1"> ' . _("JavaScript") . ' ';
73 echo ' <input type="radio" name="javascript_abook" value="0" checked> ' . _("HTML");
79 <td align
=right nowrap
><?php
echo _("Number of Messages to Index"); ?
>:
83 echo ' <tt><input type="text" size="5" name="shownum" value="'.$show_num.'"></tt><br>';
85 echo ' <tt><input type="text" size="5" name="shownum" value="25"></tt><br>';
90 <td align
="right" nowrap
><?php
echo _("Wrap incoming text at"); ?
>:
94 echo ' <tt><input type="text" size="5" name="wrapat" value="'.$wrap_at.'"></tt><br>';
96 echo ' <tt><input type="tex" size="5" name="wrapat" value="86"></tt><br>';
101 <td align
="right" nowrap
><?php
echo _("Size of editor window"); ?
>:
104 if ($editor_size >= 10 && $editor_size <= 255)
105 echo ' <tt><input type="text" size="5" name="editorsize" value="'.$editor_size.'"></tt><br>';
107 echo ' <tt><input type="text" size="5" name="editorsize" value="76"></tt><br>';
112 <td align
="right" nowrap
><?PHP
echo _("Location of folder list") ?
>:</td
>
113 <td
><select name
="folder_new_location">
114 <option value
="left"<?PHP
115 if ($location_of_bar != 'right') echo ' SELECTED';
116 ?
>><?PHP
echo _("Left"); ?
></option
>
117 <option value
="right"<?PHP
118 if ($location_of_bar == 'right') echo ' SELECTED';
119 ?
>><?PHP
echo _("Right"); ?
></option
>
124 <td align
="right" nowrap
><?PHP
echo _("Location of buttons when composing") ?
>:</td
>
125 <td
><select name
="button_new_location">
126 <option value
="top"<?PHP
127 if ($location_of_buttons == 'top') echo ' SELECTED';
128 ?
>><?PHP
echo _("Before headers"); ?
></option
>
129 <option value
="between"<?PHP
130 if ($location_of_buttons == 'between') echo ' SELECTED';
131 ?
>><?PHP
echo _("Between headers and message body"); ?
></option
>
132 <option value
="bottom"<?PHP
133 if ($location_of_buttons == 'bottom') echo ' SELECTED';
134 ?
>><?PHP
echo _("After message body"); ?
></option
>
139 <td align
=right nowrap
><?php
echo _("Width of folder list"); ?
>:
142 echo ' <select name="leftsize">' . "\n";
143 for ($i = 100; $i <= 300; $i +
= 10)
145 if ($left_size >= $i && $left_size < $i +
10)
146 echo "<option value=\"$i\" selected>$i pixels\n";
148 echo "<option value=\"$i\">$i pixels\n";
155 <td align
="right" nowrap
><?php
echo _("Auto refresh folder list"); ?
>:
158 $seconds_str = _("Seconds");
159 $none_str = _("None");
160 $minute_str = _("Minute");
161 $minutes_str = _("Minutes");
163 echo ' <SELECT name="leftrefresh">';
165 if ($left_refresh == '')
166 $left_refresh = 'None';
167 if ($left_refresh > 600)
169 RefreshOption($left_refresh, '', 'None', _("None"));
170 RefreshOption($left_refresh, 30);
171 RefreshOption($left_refresh, 60);
172 RefreshOption($left_refresh, 120);
173 RefreshOption($left_refresh, 180);
174 RefreshOption($left_refresh, 300);
175 RefreshOption($left_refresh, 600);
176 // Refreshes after the session auto-timeout (default 15 min) is pointless
178 function RefreshOption(&$current, $val, $str = '') {
181 if (is_int($val) && is_int($current)) {
182 if ($current > $lastVal && $current <= $val)
188 $str = ($val / 60) . ' ' . _("Minutes");
189 } elseif ($val == 60) {
190 $str = '1 ' . _("Minute");
192 $str = $val . ' ' . _("Seconds");
196 echo '<option value="' . $val . '"';
197 if ($val == $current)
199 echo '>' . $str . "\n";
207 <?php
echo _("Use alternating row colors?") ?
>
210 if (isset($alt_index_colors) && $alt_index_colors == 1) {
218 <input type
="radio" name
="altIndexColors" value
="1"<?php
echo $a ?
>> <?php
echo _("Yes") ?
>  
; 
;
219 <input type
="radio" name
="altIndexColors" value
="0"<?php
echo $b ?
>> <?php
echo _("No") ?
><br
>
224 <?php
echo _("Show HTML version by default"); ?
>:
227 <input type
=checkbox name
=showhtmldefault
<?php
228 if (isset($show_html_default) && $show_html_default)
231 echo _("Yes, show me the HTML version of a mail message, if it is available.");
235 <?php
do_hook('options_display_inside'); ?
>
239 <input type
="submit" value
="<?php echo _("Submit
"); ?>"name
="submit_display">
245 <?php
do_hook('options_display_bottom'); ?
>