Changeset 24212


Ignore:
Timestamp:
08/21/13 22:09:21 (6 years ago)
Author:
Eric
Message:

Next version is 2.50.11 :
Evolution 2951 fixed - Add an option to add the gallery URL at the end of emails sent by UAM
Update ru_RU, thanks to : Konve
Update lv_LV, thanks to : agrisans
Add pt_PT, thanks to : ANO

Location:
extensions/UserAdvManager/trunk
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • extensions/UserAdvManager/trunk/admin/UAM_admin.php

    r23516 r24212  
    110110  case 'global': 
    111111 
    112   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_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']) and isset($_POST['UAM_PwdReset']) and isset($_POST['UAM_RejectConnexion'])) 
     112  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_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']) and isset($_POST['UAM_PwdReset']) and isset($_POST['UAM_RejectConnexion']) and isset($_POST['UAM_AddURL2Mail'])) 
    113113  { 
    114114 
     
    263263    $newconf_UAM['GTREMINDER_SUBJECT'] = (isset($_POST['UAM_GTReminder_Subject']) ? $_POST['UAM_GTReminder_Subject'] : l10n('UAM_Default_GTReminder_Subject')); 
    264264    $newconf_UAM['ADMINVALIDATIONMAIL_SUBJECT'] = (isset($_POST['UAM_AdminValidationMail_Subject']) ? $_POST['UAM_AdminValidationMail_Subject'] : l10n('UAM_Default_AdminValidationMail_Subject')); 
     265    $newconf_UAM['ADD_GALLERY_URL_TO_EMAILS'] = (isset($_POST['UAM_AddURL2Mail']) ? $_POST['UAM_AddURL2Mail'] : 'false'); 
    265266 
    266267    $conf['UserAdvManager'] = serialize($newconf_UAM); 
     
    670671            'UAM_GTREMINDER_SUBJECT'            => $conf_UAM['GTREMINDER_SUBJECT'], 
    671672            'UAM_ADMINVALIDATIONMAIL_SUBJECT'   => $conf_UAM['ADMINVALIDATIONMAIL_SUBJECT'], 
     673            'UAM_ADDURL2MAIL_TRUE'              => $conf_UAM['ADD_GALLERY_URL_TO_EMAILS']=='true' ? 'checked="checked"' : '' , 
     674            'UAM_ADDURL2MAIL_FALSE'             => $conf_UAM['ADD_GALLERY_URL_TO_EMAILS']=='false' ? 'checked="checked"' : '' , 
    672675                                                'UAM_PASSWORD_TEST_SCORE'           => $UAM_Password_Test_Score, 
    673676            'UAM_ERROR_REPORTS1'                => $UAM_Exclusionlist_Error, 
  • extensions/UserAdvManager/trunk/admin/template/global.tpl

    r21747 r24212  
    316316                  {'UAM_Enable'|@translate} 
    317317                </label> 
    318                
    319318              </li> 
    320319            </ul> 
     
    418417          <a id="show_UAM_Change" >{'UAM_Change'|translate}</a> 
    419418          <a id="hide_UAM_Change" style="display: none">{'hide details'|translate}</a> 
    420           <ul id="UAM_Change" style="display: none"> 
     419          <fieldset id="UAM_Change" style="display: none"> 
     420          <ul> 
    421421            <div id="uam_notice">{'UAM_Confirm_grpstat_notice'|@translate}</div> 
    422422              <br/> 
     
    491491              </ul> 
    492492            </ul> 
     493            </fieldset> 
    493494          <br/><hr/><br/> 
    494495            <ul> 
     
    515516            <a id="show_UAM_ConfirmMail" >{'UAM_Customize_messagesandmails'|translate}</a> 
    516517            <a id="hide_UAM_ConfirmMail" style="display: none">{'hide details'|translate}</a> 
    517               <ul id="UAM_ConfirmMail" style="display: none"> 
     518            <fieldset id="UAM_ConfirmMail" style="display: none"> 
     519              <ul> 
    518520                <li> 
    519521                  <label class="cluetip" title="{'UAM_ConfirmMail_ReMail_Subject'|translate}|{'UAM_ConfirmMail_ReMail_Subject_d'|translate}"> 
     
    561563                </ul> 
    562564              </ul> 
     565            </fieldset> 
    563566            </ul> 
    564567          <fieldset id="UAM_ConfirmMail_field" {if $UAM_CONFIRMMAIL_TIMEOUT_FALSE and $UAM_CONFIRMMAIL_REMAIL_FALSE}style="display:none"{/if}> 
     
    633636          <a id="show_UAM_GTReminder" >{'UAM_Customize_messagesandmails'|translate}</a> 
    634637          <a id="hide_UAM_GTReminder" style="display: none">{'hide details'|translate}</a> 
    635           <ul id="UAM_GTReminder" style="display: none"> 
     638          <fieldset id="UAM_GTReminder" style="display: none"> 
     639          <ul> 
    636640            <li> 
    637641              <label class="cluetip" title="{'UAM_GTReminder_Subject'|translate}|{'UAM_GTReminder_Subject_d'|translate}"> 
     
    659663   
    660664          </ul> 
     665          </fieldset> 
    661666          <br><hr><br> 
    662667          <ul> 
     
    788793              {'UAM_Enable'|@translate} 
    789794            </label> 
    790            
    791795          </li> 
     796 
     797            <li> 
     798              <label class="cluetip" title="{'UAM_AddURL2Mail'|translate}|{'UAM_AddURL2Mail_d'|translate}"> 
     799                {'UAM_AddURL2Mail'|@translate} 
     800              </label> 
     801              <label for="UAM_AddURL2Mail_false"><input id="UAM_AddURL2Mail_false" value="false" {$UAM_ADDURL2MAIL_FALSE} name="UAM_AddURL2Mail" type="radio"/> 
     802                {'UAM_Disable'|@translate} 
     803              </label> 
     804              <label for="UAM_AddURL2Mail_true"><input id="UAM_AddURL2Mail_true" value="true" {$UAM_ADDURL2MAIL_TRUE} name="UAM_AddURL2Mail" type="radio"/> 
     805                {'UAM_Enable'|@translate} 
     806              </label> 
     807            </li> 
     808 
    792809        </ul> 
    793         <fieldset id="UAM_MAIL_INFO" {if $UAM_MAIL_INFO_FALSE}style="display:none"{/if}> 
     810        <fieldset id="UAM_MAIL_INFO" {if $UAM_MAIL_INFO_FALSE} style="display:none"{/if}> 
    794811          <ul> 
    795812            <li> 
     
    856873              {'UAM_Enable'|@translate} 
    857874            </label> 
    858            
    859875          </li> 
    860876 
  • extensions/UserAdvManager/trunk/changelog.txt.php

    r23902 r24212  
    438438             Update de_DE, thanks to : Yogie 
    439439             Update ru_RU, thanks to : Konve 
     440 
     441-- 2.50.11 : Evolution 2951 fixed - Add an option to add the gallery URL at the end of emails sent by UAM 
     442             Update ru_RU, thanks to : Konve 
     443             Update lv_LV, thanks to : agrisans 
     444             Add pt_PT, thanks to : ANO 
     445 
    440446*/ 
    441447?> 
  • extensions/UserAdvManager/trunk/include/functions.inc.php

    r23902 r24212  
    13741374        elseif ((isset($conf_UAM['CONFIRM_MAIL']) and $conf_UAM['CONFIRM_MAIL'] == 'true') and $confirm) 
    13751375        { 
    1376     pwg_mail($email, array( 
    1377       'subject' => $subject, 
    1378         'content' => (isset($infos1) ? $infos1_perso.l10n_args($infos1)."\n\n" : "").(isset($infos2) ? $infos2_perso.l10n_args($infos2)."\n\n" : "").get_absolute_root_url(), 
    1379     )); 
     1376          // Adding gallery URL at the end of the email 
     1377    if (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'true') 
     1378    { 
     1379      pwg_mail($email, array( 
     1380        'subject' => $subject, 
     1381         'content' => (isset($infos1) ? $infos1_perso.l10n_args($infos1)."\n\n" : "").(isset($infos2) ? $infos2_perso.l10n_args($infos2)."\n\n" : "").get_absolute_root_url(), 
     1382      )); 
     1383    } 
     1384    // Do not add gallery URL at the end of the email 
     1385    elseif (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'false') 
     1386    { 
     1387      pwg_mail($email, array( 
     1388        'subject' => $subject, 
     1389         'content' => (isset($infos1) ? $infos1_perso.l10n_args($infos1)."\n\n" : "").(isset($infos2) ? $infos2_perso.l10n_args($infos2)."\n\n" : ""), 
     1390      )); 
     1391    } 
     1392    // By default do not add gallery URL at the end of the email 
     1393    else 
     1394    { 
     1395      pwg_mail($email, array( 
     1396        'subject' => $subject, 
     1397         'content' => (isset($infos1) ? $infos1_perso.l10n_args($infos1)."\n\n" : "").(isset($infos2) ? $infos2_perso.l10n_args($infos2)."\n\n" : ""), 
     1398      )); 
     1399    } 
    13801400        } 
    13811401// Switching back to default language 
     
    15971617    break; 
    15981618        } 
    1599    
    1600   pwg_mail($email, array( 
    1601     'subject' => $subject, 
    1602     'content' => ($infos1."\n\n").(isset($infos2) ? l10n_args($infos2)."\n\n" : "").get_absolute_root_url(), 
    1603   )); 
    1604  
    1605                 // Switching back to default language 
    1606                 // ---------------------------------- 
    1607                 switch_lang_back(); 
     1619 
     1620  // Adding gallery URL at the end of the email 
     1621  if (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'true') 
     1622  { 
     1623    UAMLog(get_absolute_root_url(),'','',''); 
     1624    pwg_mail($email, array( 
     1625      'subject' => $subject, 
     1626      'content' => ($infos1."\n\n").(isset($infos2) ? l10n_args($infos2)."\n\n" : "").get_absolute_root_url(), 
     1627    )); 
     1628  } 
     1629  // Do not add gallery URL at the end of the email 
     1630  elseif (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'false') 
     1631  { 
     1632    pwg_mail($email, array( 
     1633      'subject' => $subject, 
     1634      'content' => ($infos1."\n\n").(isset($infos2) ? l10n_args($infos2)."\n\n" : ""), 
     1635    )); 
     1636  } 
     1637  // By default do not add gallery URL at the end of the email 
     1638  else 
     1639  { 
     1640    pwg_mail($email, array( 
     1641      'subject' => $subject, 
     1642      'content' => ($infos1."\n\n").(isset($infos2) ? l10n_args($infos2)."\n\n" : ""), 
     1643    )); 
     1644  } 
     1645 
     1646  // Switching back to default language 
     1647        // ---------------------------------- 
     1648        switch_lang_back(); 
    16081649} 
    16091650 
     
    16811722  } 
    16821723 
    1683   pwg_mail($email, array( 
    1684     'subject' => $subject, 
    1685     'content' => $infos1.get_absolute_root_url(), 
    1686   )); 
    1687  
    1688                 // Switching back to default language 
    1689                 // ---------------------------------- 
    1690                 switch_lang_back(); 
     1724  // Adding gallery URL at the end of the email 
     1725  if (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'true') 
     1726  { 
     1727    pwg_mail($email, array( 
     1728      'subject' => $subject, 
     1729      'content' => $infos1.get_absolute_root_url(), 
     1730    )); 
     1731  } 
     1732  // Do not add gallery URL at the end of the email 
     1733  elseif (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'false') 
     1734  { 
     1735    pwg_mail($email, array( 
     1736      'subject' => $subject, 
     1737      'content' => $infos1, 
     1738    )); 
     1739  } 
     1740  // By default do not add gallery URL at the end of the email 
     1741  else 
     1742  { 
     1743    pwg_mail($email, array( 
     1744      'subject' => $subject, 
     1745      'content' => $infos1, 
     1746    )); 
     1747  } 
     1748 
     1749  // Switching back to default language 
     1750        // ---------------------------------- 
     1751        switch_lang_back(); 
    16911752} 
    16921753 
     
    17871848// Sending the email with subject and contents 
    17881849// ------------------------------------------- 
    1789   pwg_mail($email, array( 
    1790     'subject' => $subject, 
    1791     'content' => ($custom_txt.l10n_args($infos1)."\n\n".l10n_args($infos2)."\n\n").get_absolute_root_url(), 
    1792   )); 
     1850  // Adding gallery URL at the end of the email 
     1851  if (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'true') 
     1852  { 
     1853    pwg_mail($email, array( 
     1854      'subject' => $subject, 
     1855      'content' => ($custom_txt.l10n_args($infos1)."\n\n".l10n_args($infos2)."\n\n").get_absolute_root_url(), 
     1856    )); 
     1857  } 
     1858  // Do not add gallery URL at the end of the email 
     1859  elseif (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'false') 
     1860  { 
     1861    pwg_mail($email, array( 
     1862      'subject' => $subject, 
     1863      'content' => ($custom_txt.l10n_args($infos1)."\n\n".l10n_args($infos2)."\n\n"), 
     1864    )); 
     1865  } 
     1866  // By default do not add gallery URL at the end of the email 
     1867  else 
     1868  { 
     1869    pwg_mail($email, array( 
     1870      'subject' => $subject, 
     1871      'content' => ($custom_txt.l10n_args($infos1)."\n\n".l10n_args($infos2)."\n\n"), 
     1872    )); 
     1873  } 
    17931874 
    17941875                // Switching back to default language 
     
    18941975// Sending the email with subject and contents 
    18951976// ------------------------------------------- 
    1896   pwg_mail($result['mail_address'], array( 
    1897     'subject' => $subject, 
    1898     'content' => (l10n_args($infos)."\n\n".$custom_txt), 
    1899   )); 
    1900  
    1901                 // Switching back to default language 
    1902                 // ---------------------------------- 
    1903                 switch_lang_back(); 
     1977  // Adding gallery URL at the end of the email 
     1978  if (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'true') 
     1979  { 
     1980    pwg_mail($result['mail_address'], array( 
     1981      'subject' => $subject, 
     1982      'content' => (l10n_args($infos)."\n\n".$custom_txt).get_absolute_root_url(), 
     1983    )); 
     1984  } 
     1985  // Do not add gallery URL at the end of the email 
     1986  elseif (isset($conf_UAM['ADD_GALLERY_URL_TO_EMAILS']) and $conf_UAM['ADD_GALLERY_URL_TO_EMAILS'] == 'false') 
     1987  { 
     1988    pwg_mail($result['mail_address'], array( 
     1989      'subject' => $subject, 
     1990      'content' => (l10n_args($infos)."\n\n".$custom_txt), 
     1991    )); 
     1992  } 
     1993  // By defaukt do not add gallery URL at the end of the email 
     1994  else 
     1995  { 
     1996    pwg_mail($result['mail_address'], array( 
     1997      'subject' => $subject, 
     1998      'content' => (l10n_args($infos)."\n\n".$custom_txt), 
     1999    )); 
     2000  } 
     2001 
     2002  // Switching back to default language 
     2003        // ---------------------------------- 
     2004        switch_lang_back(); 
    19042005} 
    19052006 
  • extensions/UserAdvManager/trunk/include/upgradedb.inc.php

    r21075 r24212  
    805805  conf_update_param('UserAdvManager_ConfirmMail', pwg_db_real_escape_string($update_conf)); 
    806806} 
     807 
     808 
     809/* upgrade from 2.50.x to 2.50.11 */ 
     810/* ***************************** */ 
     811function upgrade_2500_25011() 
     812{ 
     813  global $conf; 
     814   
     815  load_language('plugin.lang', UAM_PATH); 
     816 
     817  // Upgrading options 
     818  // ----------------- 
     819  $query = ' 
     820SELECT value 
     821  FROM '.CONFIG_TABLE.' 
     822WHERE param = "UserAdvManager" 
     823;'; 
     824 
     825  $result = pwg_query($query); 
     826  $conf_UAM = pwg_db_fetch_assoc($result); 
     827     
     828  $Newconf_UAM = unserialize($conf_UAM['value']); 
     829 
     830  $Newconf_UAM['ADD_GALLERY_URL_TO_EMAILS'] = 'false'; 
     831 
     832  $update_conf = serialize($Newconf_UAM); 
     833 
     834  conf_update_param('UserAdvManager', pwg_db_real_escape_string($update_conf)); 
     835} 
    807836?> 
  • extensions/UserAdvManager/trunk/language/en_UK/help.lang.php

    r21695 r24212  
    349349'; 
    350350// --------- End: New or revised $lang ---- from version 2.40 
     351 
     352$lang['UAM_AddURL2Mail_d'] = 'Enabling this option will add the URL of your gallery at the end of emails generated by the plugin, like a signature.'; 
    351353?> 
  • extensions/UserAdvManager/trunk/language/en_UK/plugin.lang.php

    r23562 r24212  
    428428$lang['UAM_group "%s" updated'] = 'For best performance, the group %s was automatically set as the default group.'; 
    429429$lang['personal_content'] = 'Content'; 
     430 
     431$lang['UAM_AddURL2Mail'] = 'Add the URL of the gallery at the end of emails (like a signature)'; 
    430432?> 
  • extensions/UserAdvManager/trunk/language/fr_FR/help.lang.php

    r21695 r24212  
    343343'; 
    344344// --------- End: New or revised $lang ---- from version 2.40 
     345 
     346$lang['UAM_AddURL2Mail_d'] = 'L\'activation de cette option ajoutera l\'URL de votre galerie à la fin des emails générés par le plugin, à la manière d\'une signature.'; 
    345347?> 
  • extensions/UserAdvManager/trunk/language/fr_FR/plugin.lang.php

    r23563 r24212  
    429429$lang['UAM_group "%s" updated'] = 'Pour un meilleur fonctionnement, le groupe %s a été automatiquement positionné comme groupe par défault.'; 
    430430$lang['personal_content'] = 'Contenu'; 
     431 
     432$lang['UAM_AddURL2Mail'] = 'Ajouter l\'URL de la galerie à la fin des emails (comme une signature)'; 
    431433?> 
  • extensions/UserAdvManager/trunk/maintain.inc.php

    r21519 r24212  
    6969    'GTAUTOMAIL_SUBJECT'          => l10n('UAM_Default_GTAutoMail_Subject'), 
    7070    'GTREMINDER_SUBJECT'          => l10n('UAM_Default_GTReminder_Subject'), 
    71     'ADMINVALIDATIONMAIL_SUBJECT' => l10n('UAM_Default_AdminValidationMail_Subject') 
     71    'ADMINVALIDATIONMAIL_SUBJECT' => l10n('UAM_Default_AdminValidationMail_Subject'), 
     72    'ADD_GALLERY_URL_TO_EMAILS'   => 'false' 
    7273  ); 
    7374   
     
    412413      upgrade_2410_2500(); 
    413414    } 
     415 
     416    if (version_compare($conf['UserAdvManager_Version'], '2.50.11') < 0) 
     417    { 
     418    /* upgrade from version 2.50.x to 2.50.11 */ 
     419    /* ************************************** */ 
     420      upgrade_2500_25011(); 
     421    } 
    414422  } 
    415423 
Note: See TracChangeset for help on using the changeset viewer.