Forums / Templates, Stylesheets, Page Layout / How to point to a different email template?

How to point to a different email template?

Locked

Views: 655

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
8 Oct 2010, 9:24 PM
#1
jim2005 avatar

jim2005

New Zenner

Join Date:
Oct 2010
Posts:
3
Plugin Contributions:
0

How to point to a different email template?

Hello all,

Wonder if anyone can help with this.
As some of you may know On confirmation of an order zen cart sends a e-mail to the customer and one to admin (if specified).

What zen cart does at the moment as far as I understand, bolts on the $EXTRA_INFO part for the admin to the bottom of the same email_template_checkout.html. However I want the emails to be totally different in layout, not with just the extra_info part added.

So I looked through Zen Cart's codes. In order.php I changed the zen_mail function's arguement (at around line 1034) from "checkout_extra" to say "checkoutadmin", which is stored as the $module variable in function_email.php. As far as I under stand zen_mail function in functions_email.php passes $module to zen_build_html_email_from_template function and attempts to find the template specified, which in this case should be email_template_checkoutadmin.html (which I have created, and put in the correct folder), however I do not get the correct output. The email output I get for the customer is correct, but for the admin email, it reverts back to a simple text email, which is what happens when the function doesnt find the corresponding html template.

Can someone point out to me what I need to correct / do. Or suggest an alternative way to send 2 different emails on order confirmation.

Many Thanks,

Jim

8 Oct 2010, 10:55 PM
#2
kobra avatar

kobra

Black Belt

Join Date:
Aug 2005
Location:
Arizona
Posts:
31,500
Plugin Contributions:
4

Re: How to point to a different email template?

Check setting
admin > config > email > Email Admin Format? >

Zen-Venom Get Bitten

9 Oct 2010, 11:06 AM
#3
jim2005 avatar

jim2005

New Zenner

Join Date:
Oct 2010
Posts:
3
Plugin Contributions:
0

Re: How to point to a different email template?

Nope, html format is already turned on for admin emails, so thats not the reason why the new template isnt being "read".

Jim

9 Oct 2010, 12:06 PM
#4
jim2005 avatar

jim2005

New Zenner

Join Date:
Oct 2010
Posts:
3
Plugin Contributions:
0

Re: How to point to a different email template?

Its working now, I guess I was just too tired last night, it was a simple typo error XD

Jim