Post by vryannn » Sat Jun 20, 2015 5:53 am

Hi guys,

How do I get my invoice to include the customers email in there?
I am using O.C 2.0

New member

Posts

Joined
Sat Mar 23, 2013 7:50 am

Post by IP_CAM » Sun Jun 21, 2015 3:50 am

This is not for Customer eMails, but for Admin Invoices, capable to be resent to Customers, if required.
But basically, I guess, it's important for the Admin, to know.
If this is, what your'e looking for:
In:

Code: Select all

opencart-2.0.3.1\upload\admin\view\template\sale\order_invoice.tpl
find:

Code: Select all

        <tr>
          <td><address>
            <?php echo $order['payment_address']; ?>
            </address></td>
          <td><address>
            <?php echo $order['shipping_address']; ?>
            </address></td>
        </tr>
change it to:

Code: Select all

        <tr>
          <td><address>
            <?php echo $order['payment_address']; ?>
            <br /><?php echo $order['email']; ?>
            </address></td>
          <td><address>
            <?php echo $order['shipping_address']; ?>
            </address></td>
        </tr>
or:

Code: Select all

        <tr>
          <td><address>
            <?php echo $order['payment_address']; ?>
            </address>
            <br /><?php echo $order['email']; ?>
            </td>
          <td><address>
            <?php echo $order['shipping_address']; ?>
            </address></td>
        </tr>
In the OC v.1.5.6.y Versions, it works this way, but possibly, the:

Code: Select all

$order['email']
Variable still has to be defined/declared, in the appropriate controller & language File.
Or then, it already exists, but carries another Name... (I'm not v.2. Insider!)

Try it out, but empty your cache first, to make it work, if it would...
Ernie
ipc.li/shop/

PS: it has been written about here, as well:
http://forum.opencart.com/viewtopic.php?f=72&t=145898
and it is default part of some of the popular (v.1.5.6.x) OC PDF-Printput Mod's as well.
Last edited by IP_CAM on Tue Jun 23, 2015 11:03 am, edited 1 time in total.

My Github OC Site: https://github.com/IP-CAM
5'600 + FREE OC Extensions, on the World's largest private Github OC Repository Archive Site.


User avatar
Legendary Member

Posts

Joined
Tue Mar 04, 2014 1:37 am
Location - Switzerland

Post by vryannn » Tue Jun 23, 2015 10:21 am

That worked! Thanks!

New member

Posts

Joined
Sat Mar 23, 2013 7:50 am
Who is online

Users browsing this forum: No registered users and 26 guests