tapukatata Posted December 28, 2017 Share Posted December 28, 2017 At the moment the module Mail Alert send me an email when there is a new order BUT the module send me an email with fields FROM: ; TO: and REPLY-TO with my email. I want to change the email field Reply-To be the same as customer email and when I reply to be FROM: (my email) -- TO: (customer email) is it possibe? thank you! Link to comment Share on other sites More sharing options...
shacker Posted December 28, 2017 Share Posted December 28, 2017 edit the mailalerts.php file in mailalerts module folder, you find Mail::Send( $mail_id_lang, 'new_order', sprintf(Mail::l('New order : #%d - %s', $mail_id_lang), $order->id, $order->reference), $template_vars, $merchant_mail, null, $configuration['PS_SHOP_EMAIL'], $configuration['PS_SHOP_NAME'], null, null, $dir_mail, null, $id_shop ); this function have some params, you can change in this order: * Send Email * * @param int $id_lang Language ID of the email (to translate the template) * @param string $template Template: the name of template not be a var but a string ! * @param string $subject Subject of the email * @param string $template_vars Template variables for the email * @param string|array $to To email * @param string|array $to_name To name * @param string $from From email * @param string $from_name To email * @param array $file_attachment Array with three parameters (content, mime and name). You can use an array of array to attach multiple files * @param bool $mode_smtp SMTP mode (deprecated) * @param string $template_path Template path * @param bool $die Die after error * @param int $id_shop Shop ID * @param string|array $bcc Bcc recipient(s) (email address) * @param string $reply_to Email address for setting the Reply-To header * @return bool|int Whether sending was successful. If not at all, false, otherwise amount of recipients succeeded. */ public static function Send($id_lang, $template, $subject, $template_vars, $to, $to_name = null, $from = null, $from_name = null, $file_attachment = null, $mode_smtp = null, $template_path = _PS_MAIL_DIR_, $die = false, $id_shop = null, $bcc = null, $reply_to = null) { Link to comment Share on other sites More sharing options...
tapukatata Posted December 29, 2017 Author Share Posted December 29, 2017 Hi, I found the file but I am not sure what I need to edit. Sorry but I have almost no php knowledge. Can you tell me exactly what I need to change. I just want when I give Reply to an email the fileds "Reply-To" to be with the customer email address. I have attached my mailaler.php thank you! mailalerts.php Link to comment Share on other sites More sharing options...
tapukatata Posted January 2, 2018 Author Share Posted January 2, 2018 could you help me, please! 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