Index: /extensions/UserAdvManager/branches/2.20/admin/UAM_admin.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/admin/UAM_admin.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/admin/UAM_admin.php	(revision 10392)
@@ -106,5 +106,5 @@
   case 'global':
 
-	if (isset($_POST['submit']) and isset($_POST['UAM_Mail_Info']) and isset($_POST['UAM_Username_Char']) and isset($_POST['UAM_Confirm_Mail']) and isset($_POST['UAM_No_Comment_Anonymous']) and isset($_POST['UAM_Password_Enforced']) and isset($_POST['UAM_AdminPassword_Enforced']) and isset($_POST['UAM_GhostUser_Tracker']) and isset($_POST['UAM_Admin_ConfMail']) and isset($_POST['UAM_RedirToProfile']) and isset($_POST['UAM_GTAuto']) and isset($_POST['UAM_GTAutoMail']) and isset($_POST['UAM_CustomPasswRetr']) and isset($_POST['UAM_USRAuto']) and isset($_POST['UAM_USRAutoMail']) and isset($_POST['UAM_Stuffs']))
+	if (isset($_POST['submit']) and isset($_POST['UAM_Mail_Info']) and isset($_POST['UAM_Username_Char']) and isset($_POST['UAM_Confirm_Mail']) and isset($_POST['UAM_No_Comment_Anonymous']) and isset($_POST['UAM_Password_Enforced']) and isset($_POST['UAM_AdminPassword_Enforced']) and isset($_POST['UAM_GhostUser_Tracker']) and isset($_POST['UAM_Admin_ConfMail']) and isset($_POST['UAM_RedirToProfile']) and isset($_POST['UAM_GTAuto']) and isset($_POST['UAM_GTAutoMail']) and isset($_POST['UAM_CustomPasswRetr']) and isset($_POST['UAM_USRAuto']) and isset($_POST['UAM_USRAutoMail']) and isset($_POST['UAM_Stuffs']) and isset($_POST['UAM_HidePassw']))
   {
 
@@ -178,5 +178,6 @@
       $_POST['UAM_USRAutoDelText'],
       $_POST['UAM_USRAutoMail'],
-      $_POST['UAM_Stuffs']
+      $_POST['UAM_Stuffs'],
+      $_POST['UAM_HidePassw']
       );
 
@@ -446,4 +447,6 @@
     'UAM_STUFFS_TRUE'                => $conf_UAM[34]=='true' ?  'checked="checked"' : '' ,
     'UAM_STUFFS_FALSE'               => $conf_UAM[34]=='false' ?  'checked="checked"' : '' ,
+    'UAM_HIDEPASSW_TRUE'             => $conf_UAM[35]=='true' ?  'checked="checked"' : '' ,
+    'UAM_HIDEPASSW_FALSE'            => $conf_UAM[35]=='false' ?  'checked="checked"' : '' ,
 		'UAM_PASSWORD_TEST_SCORE'        => $UAM_Password_Test_Score,
     'UAM_ERROR_REPORTS4'             => $UAM_Exclusionlist_Error,
Index: /extensions/UserAdvManager/branches/2.20/admin/template/global.tpl
===================================================================
--- /extensions/UserAdvManager/branches/2.20/admin/template/global.tpl	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/admin/template/global.tpl	(revision 10392)
@@ -184,4 +184,17 @@
           <fieldset>
             <ul>
+              <li>
+                <label class="cluetip" title="{'UAM_HidePasswTitle'|translate}|{'UAM_HidePasswTitle_d'|translate}">
+                  {'UAM_HidePassw'|@translate}
+                </label>
+              <br><br>
+                <input type="radio" value="false" {$UAM_HIDEPASSW_FALSE} name="UAM_HidePassw">
+                  {'UAM_Disable'|@translate}
+              <br>
+                <input type="radio" value="true" {$UAM_HIDEPASSW_TRUE} name="UAM_HidePassw">
+                  {'UAM_Enable'|@translate}
+              <br><br>
+              </li>
+          
               <li>
                 <label class="cluetip" title="{'UAM_infotxtTitle'|translate}|{'UAM_infotxtTitle_d'|translate}">
Index: /extensions/UserAdvManager/branches/2.20/changelog.txt.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/changelog.txt.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/changelog.txt.php	(revision 10392)
@@ -242,4 +242,5 @@
             Bug 2258 fixed - New feature to backup UAM configuration and personnal settings
 
+-- 2.20.4 : Bug 2265 fixed - Add new option to display or not user's password in information email
 */
 ?>
Index: /extensions/UserAdvManager/branches/2.20/include/functions.inc.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/include/functions.inc.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/include/functions.inc.php	(revision 10392)
@@ -858,13 +858,24 @@
   if (isset($conf_UAM[0]) and $conf_UAM[0] == 'true')
   {
-    $infos1 = array(
-      get_l10n_args('UAM_infos_mail %s', stripslashes($username)),
-      get_l10n_args('UAM_User: %s', stripslashes($username)),
-      get_l10n_args('UAM_Password: %s', $password),
-      get_l10n_args('Email: %s', $email),
-      get_l10n_args('', ''),
-    );
-  }
-
+    if (isset($conf_UAM[35]) and $conf_UAM[35] == 'false') // Allow display of clear password in email
+    {
+      $infos1 = array(
+        get_l10n_args('UAM_infos_mail %s', stripslashes($username)),
+        get_l10n_args('UAM_User: %s', stripslashes($username)),
+        get_l10n_args('UAM_Password: %s', $password),
+        get_l10n_args('Email: %s', $email),
+        get_l10n_args('', ''),
+      );
+    }
+    else // Do not allow display of clear password in email
+    {
+      $infos1 = array(
+        get_l10n_args('UAM_infos_mail %s', stripslashes($username)),
+        get_l10n_args('UAM_User: %s', stripslashes($username)),
+        get_l10n_args('Email: %s', $email),
+        get_l10n_args('', ''),
+      );
+    }
+  }
 
   if ( isset($conf_UAM[1]) and $conf_UAM[1] == 'true' and $confirm)
Index: /extensions/UserAdvManager/branches/2.20/include/upgradedb.inc.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/include/upgradedb.inc.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/include/upgradedb.inc.php	(revision 10392)
@@ -398,3 +398,35 @@
   }
 }
+
+/* upgrade from 2.20.3 to 2.20.4 */
+/* ***************************** */
+function upgrade_2203_2204()
+{
+  global $conf;
+
+  // Upgrading options
+  $query = '
+SELECT value
+  FROM '.CONFIG_TABLE.'
+WHERE param = "UserAdvManager"
+;';
+
+  $result = pwg_query($query);
+  $conf_UAM = pwg_db_fetch_assoc($result);
+    
+  $Newconf_UAM = unserialize($conf_UAM['value']);
+  
+  $Newconf_UAM[35] = 'false';
+  
+  $update_conf = serialize($Newconf_UAM);
+    
+  $query = '
+UPDATE '.CONFIG_TABLE.'
+SET value="'.addslashes($update_conf).'"
+WHERE param="UserAdvManager"
+LIMIT 1
+;';
+
+	pwg_query($query);
+}
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/de_DE/help/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/de_DE/help/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/de_DE/help/plugin.lang.php	(revision 10392)
@@ -279,3 +279,9 @@
 Die Erholung von dieser Schnittstelle wird nicht unterstützt. Verwenden Sie Tools wie phpMyAdmin.';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePasswTitle'] = 'Passwort im Klartext in der Informations-E-Mail';
+/*TODO*/$lang['UAM_HidePasswTitle_d'] = 'Choose here if you want to display the password chosen by the visitor in the information email. If you enable the option, the password will then appear in clear text. If you disable the password will not appear at all.';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/de_DE/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/de_DE/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/de_DE/plugin.lang.php	(revision 10392)
@@ -325,3 +325,8 @@
 $lang['UAM_Dump_NOK'] = 'Fehler: Backup-Datei kann nicht erstellt werden !';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePassw'] = 'Passwort im Klartext in der Informations-E-Mail';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/en_UK/help/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/en_UK/help/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/en_UK/help/plugin.lang.php	(revision 10392)
@@ -279,3 +279,9 @@
 The recovery from this interface is not supported. Use tools like phpMyAdmin.';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePasswTitle'] = 'Password in clear text in the information email';
+$lang['UAM_HidePasswTitle_d'] = 'Choose here if you want to display the password chosen by the visitor in the information email. If you enable the option, the password will then appear in clear text. If you disable the password will not appear at all.';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/en_UK/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/en_UK/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/en_UK/plugin.lang.php	(revision 10392)
@@ -327,3 +327,8 @@
 $lang['UAM_Dump_NOK'] = 'Error: Unable to create backup file !';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePassw'] = 'Password in clear text in the information email';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/es_ES/help/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/es_ES/help/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/es_ES/help/plugin.lang.php	(revision 10392)
@@ -275,3 +275,9 @@
 The recovery from this interface is not supported. Use tools like phpMyAdmin.';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePasswTitle'] = 'Contraseña en texto claro en la información del correo electrónico';
+/*TODO*/$lang['UAM_HidePasswTitle_d'] = 'Choose here if you want to display the password chosen by the visitor in the information email. If you enable the option, the password will then appear in clear text. If you disable the password will not appear at all.';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/es_ES/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/es_ES/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/es_ES/plugin.lang.php	(revision 10392)
@@ -365,3 +365,8 @@
 /*TODO*/$lang['UAM_Dump_NOK'] = 'Error: Unable to create backup file !';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePassw'] = 'Contraseña en texto claro en la información del correo electrónico';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/fr_FR/help/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/fr_FR/help/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/fr_FR/help/plugin.lang.php	(revision 10392)
@@ -275,3 +275,9 @@
 La restauration à partir de cette interface n\'est pas prise en charge. Utilisez des outils comme PhpMyAdmin.';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePasswTitle'] = 'Mot de passe en clair dans le mail d\'information';
+$lang['UAM_HidePasswTitle_d'] = 'Choisissez ici si vous souhaitez faire afficher le mot de passe choisi par le visiteur dans le mail d\'information. Si vous activez l\'option, le mot de passe apparaitra alors en clair. Si vous la désactivez, le mot de passe n\'apparaitra pas du tout.';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/fr_FR/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/fr_FR/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/fr_FR/plugin.lang.php	(revision 10392)
@@ -326,3 +326,8 @@
 $lang['UAM_Dump_NOK'] = 'Erreur : Impossible de créer le fichier de sauvegarde !';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePassw'] = 'Mot de passe en clair dans le mail d\'information';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/it_IT/help/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/it_IT/help/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/it_IT/help/plugin.lang.php	(revision 10392)
@@ -266,3 +266,9 @@
 The recovery from this interface is not supported. Use tools like phpMyAdmin.';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePasswTitle'] = 'Password in chiaro nelle informazioni e-mail';
+/*TODO*/$lang['UAM_HidePasswTitle_d'] = 'Choose here if you want to display the password chosen by the visitor in the information email. If you enable the option, the password will then appear in clear text. If you disable the password will not appear at all.';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/it_IT/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/it_IT/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/it_IT/plugin.lang.php	(revision 10392)
@@ -324,3 +324,8 @@
 /*TODO*/$lang['UAM_Dump_NOK'] = 'Error: Unable to create backup file !';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+$lang['UAM_HidePassw'] = 'Password in chiaro nelle informazioni e-mail';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/lv_LV/help/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/lv_LV/help/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/lv_LV/help/plugin.lang.php	(revision 10392)
@@ -301,3 +301,9 @@
 The recovery from this interface is not supported. Use tools like phpMyAdmin.';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+/*TODO*/$lang['UAM_HidePasswTitle'] = 'Password in clear text in the information email';
+/*TODO*/$lang['UAM_HidePasswTitle_d'] = 'Choose here if you want to display the password chosen by the visitor in the information email. If you enable the option, the password will then appear in clear text. If you disable the password will not appear at all.';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/language/lv_LV/plugin.lang.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/language/lv_LV/plugin.lang.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/language/lv_LV/plugin.lang.php	(revision 10392)
@@ -362,3 +362,8 @@
 /*TODO*/$lang['UAM_Dump_NOK'] = 'Error: Unable to create backup file !';
 // --------- End: New or revised $lang ---- from version 2.20.3
+
+
+// --------- Starting below: New or revised $lang ---- from version 2.20.4
+/*TODO*/$lang['UAM_HidePassw'] = 'Clear password in information email';
+// --------- End: New or revised $lang ---- from version 2.20.4
 ?>
Index: /extensions/UserAdvManager/branches/2.20/main.inc.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/main.inc.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/main.inc.php	(revision 10392)
@@ -2,5 +2,5 @@
 /*
 Plugin Name: UserAdvManager
-Version: 2.20.3
+Version: 2.20.4
 Description: Renforcer la gestion des utilisateurs - Enforce users management
 Plugin URI: http://piwigo.org/ext/extension_view.php?eid=216
Index: /extensions/UserAdvManager/branches/2.20/maintain.inc.php
===================================================================
--- /extensions/UserAdvManager/branches/2.20/maintain.inc.php	(revision 10391)
+++ /extensions/UserAdvManager/branches/2.20/maintain.inc.php	(revision 10392)
@@ -22,5 +22,5 @@
 Best regards,
 
-The admin of the gallery.','false','false','false','false','false','Sorry [username], your account has been deleted due to a too long time passed since your last visit at [mygallery].','Sorry [username], your account has been deprecated due to a too long time passed since your last visit at [mygallery]. Please, use the following link to revalidate your account.',-1,-1,'Thank you for registering at [mygallery]. Your account has been manually validated by _admin_. You may now log in at _link_to_site_ and make any appropriate changes to your profile. Welcome to _name_of_site_!','false','You have requested a password reset on our gallery. Please, find below your new connection settings.','false','Sorry, your account has been deleted because you have not validated your registration in requested time. Please, try registration with a valid and non blocked email account.','false','false');
+The admin of the gallery.','false','false','false','false','false','Sorry [username], your account has been deleted due to a too long time passed since your last visit at [mygallery].','Sorry [username], your account has been deprecated due to a too long time passed since your last visit at [mygallery]. Please, use the following link to revalidate your account.',-1,-1,'Thank you for registering at [mygallery]. Your account has been manually validated by _admin_. You may now log in at _link_to_site_ and make any appropriate changes to your profile. Welcome to _name_of_site_!','false','You have requested a password reset on our gallery. Please, find below your new connection settings.','false','Sorry, your account has been deleted because you have not validated your registration in requested time. Please, try registration with a valid and non blocked email account.','false','false','false');
 
 	$query = '
@@ -238,9 +238,18 @@
 /* Check for upgrade from 2.16 to 2.20 */
 /* *********************************** */
-  if (isset($conf['UserAdvManager_Version']) and $conf['UserAdvManager_Version'] == '2.16.0')
+  if (isset($conf['UserAdvManager_Version']) and strcmp($conf['UserAdvManager_Version'], '2.20.0') < 0)
   {
     /* upgrade from branch 2.16 to 2.20 */
     /* ******************************** */
     upgrade_216_220();
+  }
+
+/* Check for upgrade from 2.20.3 to 2.20.4 */
+/* *************************************** */
+  if (isset($conf['UserAdvManager_Version']) and strcmp($conf['UserAdvManager_Version'], '2.20.4') < 0)
+  {
+    /* upgrade from branch 2.16 to 2.20 */
+    /* ******************************** */
+    upgrade_2203_2204();
   }
 
