8 * Default page called when accessing SquirrelSpell's options.
10 * @author Konstantin Riabitsev <icon at duke.edu>
11 * @copyright 1999-2019 The SquirrelMail Project Team
12 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
15 * @subpackage squirrelspell
18 global $SQSPELL_APP, $main_options_changed_message;
20 if (!empty($main_options_changed_message))
21 $msg = $main_options_changed_message;
26 . _("Please choose which options you wish to set up:")
29 . '<li><a href="sqspell_options.php?MOD=edit_dic">'
30 . _("Edit your personal dictionary") . '</a></li>';
32 * See if more than one dictionary is defined system-wide.
33 * If so, let the user choose his preferred ones.
35 if (sizeof($SQSPELL_APP)>1) {
36 $msg .= '<li><a href="sqspell_options.php?MOD=lang_setup">'
37 . _("Set up international dictionaries")
41 * See if MCRYPT is available.
42 * If so, let the user choose whether s/he wants to encrypt the
43 * personal dictionary file.
45 if (function_exists("mcrypt_generic")) {
46 $msg .= '<li><a href="sqspell_options.php?MOD=enc_setup">'
47 . _("Encrypt or decrypt your personal dictionary")
51 . _("Personal dictionary encryption options are not available")
58 // add checkbox to enable/disable the spellcheck button on compose screen
60 $sqspell_show_button = getPref($data_dir, $username, 'sqspell_show_button', 1);
61 $msg .= '<form method="post">'
62 . '<input type="hidden" name="MOD" value="change_main_options" />'
63 . '<input type="hidden" name="smtoken" value="' . sm_generate_security_token() . '" />'
65 . '<input type="checkbox" id="sqspell_show_button" name="sqspell_show_button" value="1"';
66 if ($sqspell_show_button) {
67 $msg .= ' checked="checked"';
69 $msg .= ' /><label for="sqspell_show_button"> '
70 . sprintf(_("Show \"%s\" button when composing"), _("Check Spelling"))
72 $msg .= " <input type=\"submit\" value=\" "
73 . _("Make these changes") . " \" /></p></form>";
76 sqspell_makePage( _("SquirrelSpell Options Menu"), null, $msg);