projects
/
squirrelmail.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Happy 2015
[squirrelmail.git]
/
plugins
/
squirrelspell
/
modules
/
enc_setup.mod
diff --git
a/plugins/squirrelspell/modules/enc_setup.mod
b/plugins/squirrelspell/modules/enc_setup.mod
index 61aa61bc91b84e209a38c1309b947b1b8cbcce31..39d2e87bec0cd2f9625c55b8e279a06314f49f97 100644
(file)
--- a/
plugins/squirrelspell/modules/enc_setup.mod
+++ b/
plugins/squirrelspell/modules/enc_setup.mod
@@
-1,16
+1,16
@@
<?php
<?php
+
/**
* enc_setup.mod
/**
* enc_setup.mod
- * --------------
- * Squirrelspell module
*
*
- * Copyright (c) 1999-2005 The SquirrelMail development team
- * Licensed under the GNU GPL. For full terms see the file COPYING.
+ * Squirrelspell module
*
* This module shows the user a nice invitation to encrypt or decypt
* his/her personal dictionary and explains the caveats of such a decision.
*
*
* This module shows the user a nice invitation to encrypt or decypt
* his/her personal dictionary and explains the caveats of such a decision.
*
- * @author Konstantin Riabitsev <icon@duke.edu>
+ * @author Konstantin Riabitsev <icon at duke.edu>
+ * @copyright 1999-2015 The SquirrelMail Project Team
+ * @license http://opensource.org/licenses/gpl-license.php GNU Public License
* @version $Id$
* @package plugins
* @subpackage squirrelspell
* @version $Id$
* @package plugins
* @subpackage squirrelspell
@@
-31,13
+31,19
@@
$msg = '<script type="text/javascript"><!--'."\n"
. "\";\n"
. "//-->\n</script>";
. "\";\n"
. "//-->\n</script>";
-$words=sqspell_getWords();
+$crypted=false;
+$langs=sqspell_getSettings();
+foreach ($langs as $lang) {
+ $words=sqspell_getLang($lang);
+ if ($SQSPELL_CRYPTO) $crypted = true;
+}
+
/**
* When getting the user dictionary, the SQSPELL_CRYPTO flag will be
* set to "true" if the dictionary is encrypted, or "false" if it is
* in plain text.
*/
/**
* When getting the user dictionary, the SQSPELL_CRYPTO flag will be
* set to "true" if the dictionary is encrypted, or "false" if it is
* in plain text.
*/
-if ($
SQSPELL_CRYPTO
){
+if ($
crypted
){
/**
* Current format is encrypted.
* Unfortunately, the following text needs to be all on one line,
/**
* Current format is encrypted.
* Unfortunately, the following text needs to be all on one line,
@@
-54,10
+60,10
@@
if ($SQSPELL_CRYPTO){
. '</p>'
. '<form method="post" onsubmit="return checkMe()">'
. '<input type="hidden" name="MOD" value="crypto" />'
. '</p>'
. '<form method="post" onsubmit="return checkMe()">'
. '<input type="hidden" name="MOD" value="crypto" />'
- . '<p align="center"><input type="checkbox" name="action" '
- . 'value="decrypt"
/>
'
+ . '<p align="center"><input type="checkbox" name="
enc
action" '
+ . 'value="decrypt"
id="action_decrypt" /> <label for="action_decrypt">
'
. _("Please decrypt my personal dictionary and store it in a clear-text format." )
. _("Please decrypt my personal dictionary and store it in a clear-text format." )
- . '</p>'
+ . '</
label></
p>'
. '<p align="center"><input type="submit" value=" '
. _("Change crypto settings")
. ' " /></p>'
. '<p align="center"><input type="submit" value=" '
. _("Change crypto settings")
. ' " /></p>'
@@
-79,16
+85,16
@@
if ($SQSPELL_CRYPTO){
. '</p>'
. '<form method="post" onsubmit="return checkMe()">'
. '<input type="hidden" name="MOD" value="crypto" />'
. '</p>'
. '<form method="post" onsubmit="return checkMe()">'
. '<input type="hidden" name="MOD" value="crypto" />'
- . '<p align="center"><input type="checkbox" name="action" '
- . 'value="encrypt"
/>
'
+ . '<p align="center"><input type="checkbox" name="
enc
action" '
+ . 'value="encrypt"
id="action_encrypt" /> <label for="action_encrypt">
'
. _("Please encrypt my personal dictionary and store it in an encrypted format.")
. _("Please encrypt my personal dictionary and store it in an encrypted format.")
- . '</p>'
+ . '</
label></
p>'
. '<p align="center"><input type="submit" value=" '
. _("Change crypto settings") . ' " /></p>'
. '</form>';
}
sqspell_makePage(_("Personal Dictionary Crypto Settings"),
. '<p align="center"><input type="submit" value=" '
. _("Change crypto settings") . ' " /></p>'
. '</form>';
}
sqspell_makePage(_("Personal Dictionary Crypto Settings"),
- "crypto_settings.js", $msg);
+
"crypto_settings.js", $msg);
/**
* For Emacs weenies:
/**
* For Emacs weenies:
@@
-97,5
+103,3
@@
sqspell_makePage(_("Personal Dictionary Crypto Settings"),
* End:
* vim: syntax=php
*/
* End:
* vim: syntax=php
*/
-
-?>
\ No newline at end of file