Zen Cart Logo
Forums / Templates, Stylesheets, Page Layout / Formatting in custome receipt text

Formatting in custome receipt text

Locked

Views: 1,169

Results 1 to 4 of 4
This thread is locked. New replies are disabled.
3 Sep 2007, 10:17 PM
#1
cklemow avatar

cklemow

New Zenner

Join Date:
Aug 2007
Posts:
24
Plugin Contributions:
0

Formatting in custome receipt text

Hi there - I'm adding a custom header to the Order Confirmation email customers receive to replace the generic "thanks for shopping with us" message, but I'm having trouble with the formatting.

In includes/languages/english/checkout_process.php, I've tried to use <br> tags to separate lines (and put a space between the greeting header and the "details of your order" line), but they're being ignored.

Here's the code:

define('EMAIL_THANKS_FOR_SHOPPING','This confirms your Sacred Fools Online Box Office transaction. For show tickets, be sure to arrive on time as late seating cannot be guaranteed.<br><br>Sacred Fools Theater<br>660 N. Heliotrope Ave<br>(S. of Melrose, between Normandie & Vermont)<br><br>Limited parking available next to the theater. Note parking restrictions.<br><br>Questions/concerns (310) 281-8337 or see our website at www.SacredFools.org<br>');
define('EMAIL_DETAILS_FOLLOW','The following are the details of your order.');

I want it to look like this in the receipt:

**This confirms your Sacred Fools Online Box Office transaction. For show tickets, be sure to arrive on time as late seating cannot be guaranteed.

Sacred Fools Theater
660 N. Heliotrope Ave
(S. of Melrose, between Normandie & Vermont)

Limited parking available next to the theater. Note parking restrictions.

Questions/concerns (310) 281-8337 or see our website at https://www.SacredFools.org

The following are the details of your order.**

Instead, it looks like this:

This confirms your Sacred Fools Online Box Office transaction. For show
tickets, be sure to arrive on time as late seating cannot be
guaranteed.Sacred Fools Theater660 N. Heliotrope Ave(S. of Melrose, between
Normandie & Vermont)Limited parking available next to the theater. Note
parking restrictions.Questions/concerns (310) 281-8337 or see our website at
https://www.SacredFools.org
The following are the details of your order.

Any help appreciated. Thanks!

3 Sep 2007, 10:30 PM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Formatting in custome receipt text

You need to use ' . "\n" . ' instead of ```
<br>

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

3 Sep 2007, 10:36 PM
#3
cklemow avatar

cklemow

New Zenner

Join Date:
Aug 2007
Posts:
24
Plugin Contributions:
0

Re: Formatting in custome receipt text

DrByte:

You need to use ' . "\n" . ' instead of ```
<br>


Awesome, thanks for helping a PHP newbie.

So the below code would be correct?  (Single-quotes placed next to each other marked in red for ease of distinguishing from actual double-quotes...)

**define('EMAIL_THANKS_FOR_SHOPPING','This confirms your Sacred Fools Online Box Office transaction. For show tickets, be sure to arrive on time as late seating cannot be guaranteed.' . "\n" . '' . "\n" . 'Sacred Fools Theater' . "\n" . '660 N. Heliotrope Ave' . "\n" . '(S. of Melrose, between Normandie & Vermont)' . "\n" . '' . "\n" . 'Limited parking available next to the theater. Note parking restrictions.' . "\n" . '' . "\n" . 'Questions/concerns (310) 281-8337 or see our website at <https://www.SacredFools.org>' . "\n" . '');**

Thanks again!
3 Sep 2007, 11:14 PM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: Formatting in custome receipt text

That's the concept.

How's it working for you ?

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.