Changeset 30777 for extensions
- Timestamp:
- Dec 18, 2014, 9:57:28 PM (10 years ago)
- Location:
- extensions/UserAdvManager/branches/2.7
- Files:
-
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/UserAdvManager/branches/2.7/admin/UAM_admin.php
r30752 r30777 118 118 case 'global': 119 119 120 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_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']) and isset($_POST['UAM_RejectConnexion']) and isset($_POST['UAM_AddURL2Mail']) )120 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_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']) and isset($_POST['UAM_RejectConnexion']) and isset($_POST['UAM_AddURL2Mail']) and isset($_POST['UAM_Emails_Copy2Admins'])) 121 121 { 122 122 … … 274 274 $newconf_UAM['ADMINVALIDATIONMAIL_SUBJECT'] = (isset($_POST['UAM_AdminValidationMail_Subject']) ? $_POST['UAM_AdminValidationMail_Subject'] : l10n('UAM_Default_AdminValidationMail_Subject')); 275 275 $newconf_UAM['ADD_GALLERY_URL_TO_EMAILS'] = (isset($_POST['UAM_AddURL2Mail']) ? $_POST['UAM_AddURL2Mail'] : 'false'); 276 $newconf_UAM['EMAILS_COPY_TO_ADMINS'] = (isset($_POST['UAM_Emails_Copy2Admins']) ? $_POST['UAM_Emails_Copy2Admins'] : 'false'); 276 277 277 278 $conf['UserAdvManager'] = serialize($newconf_UAM); … … 685 686 'UAM_ADDURL2MAIL_TRUE' => $conf_UAM['ADD_GALLERY_URL_TO_EMAILS']=='true' ? 'checked="checked"' : '' , 686 687 'UAM_ADDURL2MAIL_FALSE' => $conf_UAM['ADD_GALLERY_URL_TO_EMAILS']=='false' ? 'checked="checked"' : '' , 688 'UAM_ADMINS_COPY_TRUE' => $conf_UAM['EMAILS_COPY_TO_ADMINS']=='true' ? 'checked="checked"' : '' , 689 'UAM_ADMINS_COPY_FALSE' => $conf_UAM['EMAILS_COPY_TO_ADMINS']=='false' ? 'checked="checked"' : '' , 687 690 'UAM_ERROR_REPORTS1' => $UAM_Exclusionlist_Error, 688 691 'UAM_ERROR_REPORTS2' => $UAM_Illegal_Flag_Error1, -
extensions/UserAdvManager/branches/2.7/admin/template/global.tpl
r26947 r30777 774 774 775 775 <div id="Config5" class="instructionBlockContent" style="display:none"> 776 <p class="new_in_version">{'UAM_NewFeature'|@translate}</p> 777 <div class="uam_new"> 778 <ul> 779 <li> 780 <label class="cluetip" title="{'UAM_Admins_Copy'|translate}|{'UAM_Admins_Copy_d'|translate}"> 781 {'UAM_Admins_Copy'|@translate} 782 </label> 783 784 <label for="UAM_Admins_Copy_false"><input id="UAM_Admins_Copy_false" type="radio" value="false" {$UAM_ADMINS_COPY_FALSE} name="UAM_Emails_Copy2Admins"/> 785 {'UAM_Disable'|@translate} 786 </label> 787 <label for="UAM_Admins_Copy_true"><input id="UAM_Admins_Copy_true" type="radio" value="true" {$UAM_ADMINS_COPY_TRUE} name="UAM_Emails_Copy2Admins"/> 788 {'UAM_Enable'|@translate} 789 </label> 790 </li> 791 </ul> 792 </div> 776 793 <ul> 777 794 <li> -
extensions/UserAdvManager/branches/2.7/include/functions.inc.php
r26934 r30777 1239 1239 ) 1240 1240 ); 1241 1242 // Send a copy to admins 1243 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1244 { 1245 UAM_Copy2Admins($subject,$content_confirmation); 1246 } 1241 1247 } 1242 1248 // Do not add gallery URL at the end of the email … … 1256 1262 ) 1257 1263 ); 1264 1265 // Send a copy to admins 1266 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1267 { 1268 UAM_Copy2Admins($subject,$content_confirmation); 1269 } 1258 1270 } 1259 1271 // By default do not add gallery URL at the end of the email … … 1273 1285 ) 1274 1286 ); 1287 1288 // Send a copy to admins 1289 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1290 { 1291 UAM_Copy2Admins($subject,$content_confirmation); 1292 } 1275 1293 } 1276 1294 } … … 1295 1313 ) 1296 1314 ); 1315 1316 // Send a copy to admins 1317 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1318 { 1319 UAM_Copy2Admins($subject,$content_info); 1320 } 1297 1321 } 1298 1322 // Do not add gallery URL at the end of the email … … 1312 1336 ) 1313 1337 ); 1338 1339 // Send a copy to admins 1340 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1341 { 1342 UAM_Copy2Admins($subject,$content_info); 1343 } 1314 1344 } 1315 1345 // By default do not add gallery URL at the end of the email … … 1329 1359 ) 1330 1360 ); 1361 1362 // Send a copy to admins 1363 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1364 { 1365 UAM_Copy2Admins($subject,$content_info); 1366 } 1331 1367 } 1332 1368 } … … 1500 1536 ) 1501 1537 ); 1538 1539 // Send a copy to admins 1540 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1541 { 1542 UAM_Copy2Admins($subject,$content); 1543 } 1502 1544 } 1503 1545 // Do not add gallery URL at the end of the email … … 1517 1559 ) 1518 1560 ); 1561 1562 // Send a copy to admins 1563 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1564 { 1565 UAM_Copy2Admins($subject,$content); 1566 } 1519 1567 } 1520 1568 // By default do not add gallery URL at the end of the email … … 1534 1582 ) 1535 1583 ); 1584 1585 // Send a copy to admins 1586 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1587 { 1588 UAM_Copy2Admins($subject,$content); 1589 } 1536 1590 } 1537 1591 … … 1630 1684 ) 1631 1685 ); 1686 1687 // Send a copy to admins 1688 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1689 { 1690 UAM_Copy2Admins($subject,$content); 1691 } 1632 1692 } 1633 1693 // Do not add gallery URL at the end of the email … … 1647 1707 ) 1648 1708 ); 1709 1710 // Send a copy to admins 1711 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1712 { 1713 UAM_Copy2Admins($subject,$content); 1714 } 1649 1715 } 1650 1716 // By default do not add gallery URL at the end of the email … … 1664 1730 ) 1665 1731 ); 1732 1733 // Send a copy to admins 1734 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1735 { 1736 UAM_Copy2Admins($subject,$content); 1737 } 1666 1738 } 1667 1739 … … 1783 1855 ) 1784 1856 ); 1857 1858 // Send a copy to admins 1859 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1860 { 1861 UAM_Copy2Admins($subject,$content); 1862 } 1785 1863 } 1786 1864 // Do not add gallery URL at the end of the email … … 1800 1878 ) 1801 1879 ); 1880 1881 // Send a copy to admins 1882 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1883 { 1884 UAM_Copy2Admins($subject,$content); 1885 } 1802 1886 } 1803 1887 // By default do not add gallery URL at the end of the email … … 1817 1901 ) 1818 1902 ); 1903 1904 // Send a copy to admins 1905 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 1906 { 1907 UAM_Copy2Admins($subject,$content); 1908 } 1819 1909 } 1820 1910 … … 1937 2027 ) 1938 2028 ); 2029 2030 // Send a copy to admins 2031 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 2032 { 2033 UAM_Copy2Admins($subject,$content); 2034 } 1939 2035 } 1940 2036 // Do not add gallery URL at the end of the email … … 1954 2050 ) 1955 2051 ); 2052 2053 // Send a copy to admins 2054 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 2055 { 2056 UAM_Copy2Admins($subject,$content); 2057 } 1956 2058 } 1957 2059 // By defaukt do not add gallery URL at the end of the email … … 1971 2073 ) 1972 2074 ); 2075 2076 // Send a copy to admins 2077 if ((isset($conf_UAM['EMAILS_COPY_TO_ADMINS']) and $conf_UAM['EMAILS_COPY_TO_ADMINS'] == 'true')) 2078 { 2079 UAM_Copy2Admins($subject,$content); 2080 } 1973 2081 } 1974 2082 … … 3065 3173 3066 3174 /** 3175 * UAM_Copy2Admins 3176 * Send a copy of user's email to admins 3177 * 3178 * Param : email subject and content 3179 */ 3180 function UAM_Copy2Admins($subject,$content) 3181 { 3182 $adminsubject = "[Admins Copy] - ".$subject; 3183 3184 pwg_mail_admins( 3185 array( 3186 'content' => $content, 3187 'content_format' => 'text/plain', 3188 'subject' => $adminsubject, 3189 ) 3190 ); 3191 } 3192 3193 /** 3067 3194 * SetValidated 3068 3195 * Set UAM_validated field to true in #_users table -
extensions/UserAdvManager/branches/2.7/include/upgradedb.inc.php
r25092 r30777 863 863 pwg_query($q); 864 864 } 865 866 867 /* upgrade from 2.51.x to 2.70.3 */ 868 /* ***************************** */ 869 function upgrade_2510_2703() 870 { 871 global $conf; 872 873 load_language('plugin.lang', UAM_PATH); 874 875 // Upgrading options 876 // ----------------- 877 $query = ' 878 SELECT value 879 FROM '.CONFIG_TABLE.' 880 WHERE param = "UserAdvManager" 881 ;'; 882 883 $result = pwg_query($query); 884 $conf_UAM = pwg_db_fetch_assoc($result); 885 886 $Newconf_UAM = unserialize($conf_UAM['value']); 887 888 // Add "send a copy of all emails to admins" new option 889 $Newconf_UAM['EMAILS_COPY_TO_ADMINS'] = 'false'; 890 891 $update_conf = serialize($Newconf_UAM); 892 893 conf_update_param('UserAdvManager', pwg_db_real_escape_string($update_conf)); 894 } 865 895 ?> -
extensions/UserAdvManager/branches/2.7/language/en_UK/help_config4.lang.php
r30752 r30777 6 6 ... 7 7 '; 8 $lang['UAM_Admins_Copy_d'] = 'By enabling this option, all administrators of the gallery will receive a copy of <b style="color: red;">all emails</b> sent by the plugin. This can be usefull to check if emails are really sent and to keep a copy in case of dispute. For example, during a registration validation or renewal.<br/><br/>Subjects of copied emails are prefixed with <b style="color: green;">"[Admins Copy] - "</b>'; 8 9 $lang['UAM_infomailTitle_d'] = 'This option allows to automate sending an information email to a user when he changes his password or email address in his profile page.<br/><br/> 9 10 The content of the message sent is composed of a customizable part to introduce a little welcome note and a fixed part indicating the login name, password and email address of the user.'; -
extensions/UserAdvManager/branches/2.7/language/en_UK/plugin.lang.php
r30752 r30777 92 92 $lang['UAM_ConfirmMail_ReMail_Txt1'] = 'Customizing the reminder message <b><u>with</u></b> new regeneration of confirmation key.'; 93 93 $lang['UAM_ConfirmMail_ReMail_Txt2'] = 'Customizing the reminder message <b><u>without</u></b> regeneration of confirmation key.'; 94 $lang['UAM_Admins_Copy'] = 'Copy of all emails to admins:'; 94 95 95 96 $lang['UAM_GhostTracker'] = 'Ghost visitors management (Ghost Tracker)'; … … 410 411 $lang['UAM_Select page size'] = 'Select page size'; 411 412 $lang['UAM_Select page number'] = 'Select page number'; 413 414 $lang['UAM_NewFeature'] = 'New Feature'; 412 415 ?> -
extensions/UserAdvManager/branches/2.7/language/fr_FR/help_config4.lang.php
r30752 r30777 6 6 ... 7 7 '; 8 $lang['UAM_Admins_Copy_d'] = 'En activant cette option, tous les administrateurs de la galerie seront en copie de <b style="color: red;">tous les emails</b> envoyés par le plugin. Permet de vérifier que les emails sont bien envoyés et de conserver une copie en cas de litige. Par exemple, lors d\'une validation d\'inscription ou de relance.<br/><br/>Les sujets de emails en copie sont préfixés par <b style="color: green;">"[Admins Copy] - "</b>'; 8 9 $lang['UAM_infomailTitle_d'] = 'Cette option permet d\'automatiser l\'envoi d\'un email d\'information à un utilisateur lorsqu\'il modifie son mot de passe ou son adresse de messagerie dans son profil.<br/><br/> 9 10 Le message envoyé comprend une partie fixe (login, mot de passe et adresse email de l\'utilisateur) et une partie personnalisable par un texte d\'accueil.'; -
extensions/UserAdvManager/branches/2.7/language/fr_FR/plugin.lang.php
r30752 r30777 93 93 $lang['UAM_ConfirmMail_ReMail_Txt1'] = 'Texte du message de rappel <b><u>avec</u></b> génération d\'une nouvelle clé de confirmation.'; 94 94 $lang['UAM_ConfirmMail_ReMail_Txt2'] = 'Texte du message de rappel <b><u>sans</u></b> génération d\'une nouvelle clé de confirmation.'; 95 $lang['UAM_Admins_Copy'] = 'Administrateurs en copie des emails envoyés :'; 95 96 96 97 $lang['UAM_GhostTracker'] = 'Gestion des visiteurs fantômes (Ghost Tracker)'; … … 412 413 $lang['UAM_Select page size'] = 'Choisir la taille des pages'; 413 414 $lang['UAM_Select page number'] = 'Sélectionner une page'; 415 416 $lang['UAM_NewFeature'] = 'Nouvelle fonctionnalité'; 414 417 ?> -
extensions/UserAdvManager/branches/2.7/maintain.inc.php
r29336 r30777 67 67 'GTREMINDER_SUBJECT' => l10n('UAM_Default_GTReminder_Subject'), 68 68 'ADMINVALIDATIONMAIL_SUBJECT' => l10n('UAM_Default_AdminValidationMail_Subject'), 69 'ADD_GALLERY_URL_TO_EMAILS' => 'false' 69 'ADD_GALLERY_URL_TO_EMAILS' => 'false', 70 'EMAILS_COPY_TO_ADMINS' => 'false' 70 71 ); 71 72 … … 404 405 { 405 406 /* upgrade from version 2.50.x to 2.51.0 */ 406 /* ************************************* ***/407 /* ************************************* */ 407 408 upgrade_2500_2510(); 409 } 410 411 if (version_compare($conf['UserAdvManager_Version'], '2.70.3') < 0) 412 { 413 /* upgrade from version 2.51.0 to 2.70.3 */ 414 /* ************************************* */ 415 upgrade_2510_2703(); 408 416 } 409 417 }
Note: See TracChangeset
for help on using the changeset viewer.