5haun Posted March 18, 2015 Share Posted March 18, 2015 (edited) Hi all I want to modify the Mail Alerts module. I get orders from a customer and I need the email notification for orders from that customer to go to a specific email address. Is there some way where I could put an if statement in the module to do something like:if {$id_customer == 3} send email notification to [email protected] else { send to the main email address set in the module. I'm obviously not very PHP savvy but I know my way around. Any help would to achieve this would be hugely appreciated! Edited March 19, 2015 by 5haun (see edit history) Link to comment Share on other sites More sharing options...
5haun Posted March 19, 2015 Author Share Posted March 19, 2015 bump Link to comment Share on other sites More sharing options...
rocky Posted March 19, 2015 Share Posted March 19, 2015 Search for this code at about line 392 of modules/mailalerts/mailalerts.php: $merchant_mails = explode(self::__MA_MAIL_DELIMITOR__, $this->merchant_mails); Below that, you can add code like: if ($customer->id == 3) $merchant_mails = array('[email protected]'); This should override the default merchant list for customer 3 only. 1 Link to comment Share on other sites More sharing options...
5haun Posted March 19, 2015 Author Share Posted March 19, 2015 Wow!!!Thank you Rocky! Works perfectly! You are awesome Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now