Send order confirmation to custom email field

  • Posts: 10
  • Thank you received: 0
4 years 9 months ago #308431

We need to send the emails at the end of an order to the email account specified in one of the extra fields of the billing address that I created.

It's possible? Thanks

Please Log in or Create an account to join the conversation.

  • Posts: 81504
  • Thank you received: 13064
  • MODERATOR
4 years 9 months ago #308439

Hi,

With the Business edition, you can edit the emails via the menu System>Emails.
There, in the "preload" of the email, you can add a bit of PHP to do that.
Now, I'm not sure what you mean exactly ? Do you want to send a copy of the copy to that email address ? Or you actually don't want to send the email to the normal user, only to the email address in the custom address field ?
Supposing it's the later, you can add such code at the end of the preload and it should do the trick:

$data->customer->user_email = $data->cart->billing_address->XXX;
where XXX is the column name of your custom address field.

Please Log in or Create an account to join the conversation.

  • Posts: 10
  • Thank you received: 0
4 years 9 months ago #308462

Hello, thanks for the answer. What I need is to send the confirmation mail of the order to the address that the users put in the shipping form(that is a extrafield in display tab), not the email address of the joomla user.

Where do I have to put that code to prove it?

Thank you.

Please Log in or Create an account to join the conversation.

  • Posts: 81504
  • Thank you received: 13064
  • MODERATOR
4 years 9 months ago #308463

Hi,

As I said, you need to add that code at the end of the preload section of the email when you're editing it via the menu System>Emails of HikaShop.
Please note that email edition is only available with HikaShop Business.

Please Log in or Create an account to join the conversation.

Time to create page: 0.059 seconds
Powered by Kunena Forum