From 2ad4cea967df0d35acf226cce6cd74f6ab765bd6 Mon Sep 17 00:00:00 2001 From: jervfors Date: Thu, 1 Jul 2004 15:03:30 +0000 Subject: [PATCH] Removing HTML tags from strings git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@7721 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- functions/abook_database.php | 3 +- functions/db_prefs.php | 3 +- plugins/squirrelspell/modules/crypto.mod | 81 +++++++++-------- plugins/squirrelspell/modules/enc_setup.mod | 98 ++++++++++++--------- plugins/squirrelspell/sqspell_functions.php | 8 +- po/squirrelmail.pot | 82 ++++++++++------- 6 files changed, 153 insertions(+), 122 deletions(-) diff --git a/functions/abook_database.php b/functions/abook_database.php index 82ddba9d..0377691c 100644 --- a/functions/abook_database.php +++ b/functions/abook_database.php @@ -37,7 +37,8 @@ if (!include_once('DB.php')) { // same error also in db_prefs.php require_once(SM_PATH . 'functions/display_messages.php'); $error = _("Could not include PEAR database functions required for the database backend.") . "
\n"; - $error .= _("Is PEAR installed, and is the include path set correctly to find DB.php?") . "
\n"; + $error .= sprintf(_("Is PEAR installed, and is the include path set correctly to find %s?"), + 'DB.php') . "
\n"; $error .= _("Please contact your system administrator and report this error."); error_box($error, $color); exit; diff --git a/functions/db_prefs.php b/functions/db_prefs.php index 12b26d94..065080f3 100644 --- a/functions/db_prefs.php +++ b/functions/db_prefs.php @@ -41,7 +41,8 @@ if (!include_once('DB.php')) { // same error also in abook_database.php require_once(SM_PATH . 'functions/display_messages.php'); $error = _("Could not include PEAR database functions required for the database backend.") . "
\n"; - $error .= _("Is PEAR installed, and is the include path set correctly to find DB.php?") . "
\n"; + $error .= sprintf(_("Is PEAR installed, and is the include path set correctly to find %s?"), + 'DB.php') . "
\n"; $error .= _("Please contact your system administrator and report this error."); error_box($error, $color); exit; diff --git a/plugins/squirrelspell/modules/crypto.mod b/plugins/squirrelspell/modules/crypto.mod index f06ab049..c840aa6a 100644 --- a/plugins/squirrelspell/modules/crypto.mod +++ b/plugins/squirrelspell/modules/crypto.mod @@ -1,6 +1,6 @@ ' - . _("Your personal dictionary has been encrypted and is now stored in an encrypted format.") - . '

'; - break; - case 'decrypt': - /** - * Let's decrypt the file and save it as plain text. - */ - $words=sqspell_getWords(); - /** - * Flip the flag and tell the sqspell_writeWords() function that we - * want to save it plaintext. - */ - $SQSPELL_CRYPTO=false; - sqspell_writeWords($words); - $msg='

' - . _("Your personal dictionary has been decrypted and is now stored as clear text.") - . '

'; - break; - - case "": - /** - * Wait, this shouldn't happen! :) - */ - $msg = "

No action requested.

"; - break; + case 'encrypt': + /** + * Let's encrypt the file and save it in an encrypted format. + */ + $words=sqspell_getWords(); + /** + * Flip the flag so the sqspell_writeWords function knows to encrypt + * the message before writing it to the disk. + */ + $SQSPELL_CRYPTO=true; + /** + * Call the function that does the actual encryption_decryption. + */ + sqspell_writeWords($words); + $msg='

' + . _("Your personal dictionary has been encrypted and is now stored in an encrypted format.") + . '

'; + break; + case 'decrypt': + /** + * Let's decrypt the file and save it as plain text. + */ + $words=sqspell_getWords(); + /** + * Flip the flag and tell the sqspell_writeWords() function that we + * want to save it plaintext. + */ + $SQSPELL_CRYPTO=false; + sqspell_writeWords($words); + $msg='

' + . _("Your personal dictionary has been decrypted and is now stored as plain text."), + . '

'; + break; + case '': + /** + * Wait, this shouldn't happen! :) + */ + $msg = '

No action requested.

'; + break; } sqspell_makePage( _("Personal Dictionary Crypto Settings"), null, $msg); diff --git a/plugins/squirrelspell/modules/enc_setup.mod b/plugins/squirrelspell/modules/enc_setup.mod index 0feb3067..9b76cf76 100644 --- a/plugins/squirrelspell/modules/enc_setup.mod +++ b/plugins/squirrelspell/modules/enc_setup.mod @@ -21,15 +21,15 @@ global $SQSPELL_CRYPTO; /** * Set up some i18n'able wrappers for javascript. */ -$msg = ""; +$msg = '"; $words=sqspell_getWords(); /** @@ -38,40 +38,54 @@ $words=sqspell_getWords(); * in plain text. */ if ($SQSPELL_CRYPTO){ - /** - * Current format is encrypted. - * Unfortunately, the following text needs to be all on one line, - * unless someone fixes xgettext. ;( - */ - $msg .= - _("

Your personal dictionary is currently encrypted. This helps protect your privacy in case the web-mail system gets compromized and your personal dictionary ends up stolen. It is currently encrypted with the password you use to access your mailbox, making it hard for anyone to see what is stored in your personal dictionary.

ATTENTION: If you forget your password, your personal dictionary will become unaccessible, since it can no longer be decrypted. If you change your mailbox password, SquirrelSpell will recognize it and prompt you for your old password in order to re-encrypt the dictionary with a new key.

") - . '
' - . '' - . '

' - . _("Please decrypt my personal dictionary and store it in a clear-text format." ) - . '

' - . '

' - . '
'; + /** + * Current format is encrypted. + * Unfortunately, the following text needs to be all on one line, + * unless someone fixes xgettext. ;( + */ + $msg .= + '

' + . _("Your personal dictionary is currently encrypted.") + . '

' + . _("This helps protect your privacy in case the web-mail system gets compromized and your personal dictionary ends up stolen. It is currently encrypted with the password you use to access your mailbox, making it hard for anyone to see what is stored in your personal dictionary.") + . '

' + . '' . _("ATTENTION:") . '
' + . _("If you forget your password, your personal dictionary will become unaccessible, since it can no longer be decrypted. If you change your mailbox password, SquirrelSpell will recognize it and prompt you for your old password in order to re-encrypt the dictionary with a new key.") + . '

' + . '
' + . '' + . '

' + . _("Please decrypt my personal dictionary and store it in a clear-text format." ) + . '

' + . '

' + . '
'; } else { - /** - * Current format is clear text. - * Unfortunately, the following text needs to be all on one line, - * unless someone fixes xgettext. ;( - */ - $msg .= - _("

Your personal dictionary is currently not encrypted. You may wish to encrypt your personal dictionary to protect your privacy in case the webmail system gets compromized and your personal dictionary file gets stolen. When encrypted, the file's contents look garbled and are hard to decrypt without knowing the correct key (which is your mailbox password).

ATTENTION: If you decide to encrypt your personal dictionary, you must remember that it gets "hashed" with your mailbox password. If you forget your mailbox password and the administrator changes it to a new value, your personal dictionary will become useless and will have to be created anew. However, if you or your system administrator change your mailbox password but you still have the old password at hand, you will be able to enter the old key to re-encrypt the dictionary with the new value.

") - . '
' - . '' - . '

' - . _("Please encrypt my personal dictionary and store it in an encrypted format.") - . '

' - . '

' - . '
'; + /** + * Current format is clear text. + * Unfortunately, the following text needs to be all on one line, + * unless someone fixes xgettext. ;( + */ + $msg .= + '

' + . _("Your personal dictionary is currently not encrypted.") + . '

' + . _("You may wish to encrypt your personal dictionary to protect your privacy in case the webmail system gets compromized and your personal dictionary file gets stolen. When encrypted, the file's contents look garbled and are hard to decrypt without knowing the correct key (which is your mailbox password).") + . '

' + . '' . _("ATTENTION:") . '
' + . _("If you decide to encrypt your personal dictionary, you must remember that it gets "hashed" with your mailbox password. If you forget your mailbox password and the administrator changes it to a new value, your personal dictionary will become useless and will have to be created anew. However, if you or your system administrator change your mailbox password but you still have the old password at hand, you will be able to enter the old key to re-encrypt the dictionary with the new value.") + . '

' + . '
' + . '' + . '

' + . _("Please encrypt my personal dictionary and store it in an encrypted format.") + . '

' + . '

' + . '
'; } sqspell_makePage(_("Personal Dictionary Crypto Settings"), "crypto_settings.js", $msg); diff --git a/plugins/squirrelspell/sqspell_functions.php b/plugins/squirrelspell/sqspell_functions.php index 7e97759d..4acf28d3 100644 --- a/plugins/squirrelspell/sqspell_functions.php +++ b/plugins/squirrelspell/sqspell_functions.php @@ -35,7 +35,7 @@ function sqspell_makePage($title, $scriptsrc, $body){ } displayPageHeader($color, 'None'); - echo " 
\n"; + echo " 
\n"; /** * Check if we need to link in a script. */ @@ -370,15 +370,15 @@ function sqspell_getWords(){ * gettext will bork. ;( */ $msg = html_tag( 'p', "\n" . - '' . _("ATTENTION:") . '
' - . _("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.") , + '' . _("ATTENTION:") . '
' + . _("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" . '
' . "\n" . '
' . "\n" . '' . "\n" . html_tag( 'p', "\n" . '' - . _("Delete my dictionary and start a new one") . '
' + . _("Delete my dictionary and start a new one") . '
' . _("Decrypt my dictionary with my old password:") . '' , 'left' ) . "\n" diff --git a/po/squirrelmail.pot b/po/squirrelmail.pot index cae25f10..0b9c410a 100644 --- a/po/squirrelmail.pot +++ b/po/squirrelmail.pot @@ -6,7 +6,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2004-06-12 19:14+0200\n" +"POT-Creation-Date: 2004-07-01 16:55+0200\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -967,6 +967,17 @@ msgstr "" msgid "Folder List" msgstr "" +msgid "" +"Could not include PEAR database functions required for the database backend." +msgstr "" + +#, c-format +msgid "Is PEAR installed, and is the include path set correctly to find %s?" +msgstr "" + +msgid "Please contact your system administrator and report this error." +msgstr "" + msgid "Personal address book" msgstr "" @@ -1221,9 +1232,6 @@ msgstr "" msgid "Default preference file not found or not readable!" msgstr "" -msgid "Please contact your system administrator and report this error." -msgstr "" - msgid "Could not create initial preference file!" msgstr "" @@ -3461,10 +3469,10 @@ msgid "" "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." +"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." msgstr "" msgid "Delete my dictionary and start a new one" @@ -3579,13 +3587,12 @@ msgid "No errors found" msgstr "" msgid "" -"Your personal dictionary has been encrypted and is now " -"stored in an encrypted format." +"Your personal dictionary has been encrypted and is now stored in an " +"encrypted format." msgstr "" msgid "" -"Your personal dictionary has been decrypted and is now " -"stored as clear text." +"Your personal dictionary has been decrypted and is now stored as plain text." msgstr "" msgid "Personal Dictionary Crypto Settings" @@ -3650,20 +3657,25 @@ msgid "" msgstr "" msgid "" -"This will decrypt your personal dictionary and store it in a clear-text " +"This will decrypt your personal dictionary and store it in a plain text " "format. Proceed?" msgstr "" +msgid "Your personal dictionary is currently encrypted." +msgstr "" + +msgid "" +"This helps protect your privacy in case the web-mail system gets compromized " +"and your personal dictionary ends up stolen. It is currently encrypted with " +"the password you use to access your mailbox, making it hard for anyone to " +"see what is stored in your personal dictionary." +msgstr "" + msgid "" -"

Your personal dictionary is currently encrypted. This " -"helps protect your privacy in case the web-mail system gets compromized and " -"your personal dictionary ends up stolen. It is currently encrypted with the " -"password you use to access your mailbox, making it hard for anyone to see " -"what is stored in your personal dictionary.

ATTENTION: If you forget your password, your personal dictionary will become " +"If you forget your password, your personal dictionary will become " "unaccessible, since it can no longer be decrypted. If you change your " "mailbox password, SquirrelSpell will recognize it and prompt you for your " -"old password in order to re-encrypt the dictionary with a new key.

" +"old password in order to re-encrypt the dictionary with a new key." msgstr "" msgid "" @@ -3673,20 +3685,24 @@ msgstr "" msgid "Change crypto settings" msgstr "" +msgid "Your personal dictionary is currently not encrypted." +msgstr "" + +msgid "" +"You may wish to encrypt your personal dictionary to protect your privacy in " +"case the webmail system gets compromized and your personal dictionary file " +"gets stolen. When encrypted, the file's contents look garbled and are hard " +"to decrypt without knowing the correct key (which is your mailbox password)." +msgstr "" + msgid "" -"

Your personal dictionary is currently not encrypted. You " -"may wish to encrypt your personal dictionary to protect your privacy in case " -"the webmail system gets compromized and your personal dictionary file gets " -"stolen. When encrypted, the file's contents look garbled and are hard to " -"decrypt without knowing the correct key (which is your mailbox password). ATTENTION: If you decide to encrypt your personal " -"dictionary, you must remember that it gets "hashed" with your " -"mailbox password. If you forget your mailbox password and the administrator " -"changes it to a new value, your personal dictionary will become useless and " -"will have to be created anew. However, if you or your system administrator " -"change your mailbox password but you still have the old password at hand, " -"you will be able to enter the old key to re-encrypt the dictionary with the " -"new value.

" +"If you decide to encrypt your personal dictionary, you must remember that it " +"gets "hashed" with your mailbox password. If you forget your " +"mailbox password and the administrator changes it to a new value, your " +"personal dictionary will become useless and will have to be created anew. " +"However, if you or your system administrator change your mailbox password " +"but you still have the old password at hand, you will be able to enter the " +"old key to re-encrypt the dictionary with the new value." msgstr "" msgid "" -- 2.25.1