X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=plugins%2Fsquirrelspell%2Fsqspell_functions.php;h=41c6783b0d84b84278ca889543edcb6f04d4ad27;hp=04c787149bb51614f1c93d9e8c0fec5f88d6a954;hb=353d074afac6827c90f4bb03e846c5e453d3b5b1;hpb=30460a05016c7e066ad7b28df7788539e4054a99 diff --git a/plugins/squirrelspell/sqspell_functions.php b/plugins/squirrelspell/sqspell_functions.php index 04c78714..41c6783b 100644 --- a/plugins/squirrelspell/sqspell_functions.php +++ b/plugins/squirrelspell/sqspell_functions.php @@ -6,7 +6,7 @@ * All SquirrelSpell-wide functions are in this file. * * @author Konstantin Riabitsev - * @copyright 1999-2009 The SquirrelMail Project Team + * @copyright 1999-2018 The SquirrelMail Project Team * @license http://opensource.org/licenses/gpl-license.php GNU Public License * @version $Id$ * @package plugins @@ -57,11 +57,15 @@ function squirrelspell_optpage_block_function() { * @return void */ function squirrelspell_setup_function() { + + global $data_dir, $username; + $sqspell_show_button = getPref($data_dir, $username, 'sqspell_show_button', 1); + /** * Check if this browser is capable of displaying SquirrelSpell * correctly. */ - if (checkForJavascript()) { + if ($sqspell_show_button && checkForJavascript()) { global $oTemplate, $base_uri, $nbsp; @@ -849,12 +853,12 @@ function sqspell_handle_crypt_panic($lang=false) { . _("SquirrelSpell was unable to decrypt your personal dictionary. This is most likely due to the fact that you have changed your mailbox password. In order to proceed, you will have to supply your old password so that SquirrelSpell can decrypt your personal dictionary. It will be re-encrypted with your new password after this. If you haven't encrypted your dictionary, then it got mangled and is no longer valid. You will have to delete it and start anew. This is also true if you don't remember your old password -- without it, the encrypted data is no longer accessible.") , 'left' ) . "\n" . (($lang) ? html_tag('p',sprintf(_("Your %s dictionary is encrypted with password that differs from your current password."), - htmlspecialchars($lang)),'left') : '') + sm_encode_html_special_chars($lang)),'left') : '') . '
' . "\n" . '
' . "\n" . '' . "\n" . (($lang) ? - '' : + '' : '') . html_tag( 'p', "\n" . ''