View Single Post
  #7  
Old 12-14-2003, 03:27 PM
  BoomBoomBap's Avatar 
BoomBoomBap BoomBoomBap is offline
 

Senior Member
  
Join Date: Nov 2002
Location: San Francisco
Posts: 184
 

Default

I've got this working in 3.4.10
Here are the changes:

Patch for the database to make the option appear in the general settings:
Code:
INSERT INTO xcart_config VALUES ('modify_emails', 'Modification emails sent', 'Y', 'General', 1000, 'Checkbox');

Then amend include/register.php (version 3.4.10 - line 19

Original
Code:
# # Send mail to registered user (do not send to anonymous) # if(!$anonymous_user) if ($usertype=="B") func_send_mail($email, "mail/signin_notification_subj.tpl", "mail/signin_partner_notif.tpl", $config["Company"]["users_department"], false); else func_send_mail($email, "mail/signin_notification_subj.tpl", "mail/signin_notification.tpl", $config["Company"]["users_department"], false); # # Send mail to customers department # if(!$anonymous_user) func_send_mail($config["Company"]["users_department"], "mail/signin_admin_notif_subj.tpl", "mail/signin_admin_notification.tpl", $email, true);

New
Code:
# # Send mail to registered user (do not send to anonymous) # if ($config["General"]["modify_emails"]=="Y"){ if(!$anonymous_user) if ($usertype=="B") func_send_mail($email, "mail/signin_notification_subj.tpl", "mail/signin_partner_notif.tpl", $config["Company"]["users_department"], false); else func_send_mail($email, "mail/signin_notification_subj.tpl", "mail/signin_notification.tpl", $config["Company"]["users_department"], false); # # Send mail to customers department # if(!$anonymous_user) func_send_mail($config["Company"]["users_department"], "mail/signin_admin_notif_subj.tpl", "mail/signin_admin_notification.tpl", $email, true); }

Once this mod is implemented, you will find a new checkbox at the bottom of General Settings in the Admin area. Check the box to enable notifications, leave empty to disable them.

Note: the change to register.php is just adding the "if" statement.

What an amazingly simple and effective mod. Thanks !
__________________
Site 1 > XCART LIVE 3.4.12

Site 2 > XCART LIVE 4.0.17
Reply With Quote