Page 2 of 3
Re: Add Store logo to invoice
Posted: Fri Jul 22, 2011 2:50 am
by neatpleats
This worked on 1.5.5 as well. Just don't use the word title as the logo, use the name of your logo, ie, logo.php instead.
<img src="
http://neatpleats.com/image/data/NPlogo ... ><h1><?php echo $text_invoice; ?></h1>
Re: Add product picture on invoice,
Posted: Sat Nov 12, 2011 4:38 am
by neatpleats
Is there any way to add a picture of the product on the invoice next to the product description? I just need a visual helper to make sure I am pulling the right product.
Scott
Re: Add Store logo to invoice
Posted: Sat Feb 04, 2012 3:15 am
by Nile
Thanks to ifyouseek, I followed....
And it worked great.
However i'm running 1.5.1.3 and theres no file called admin/view/template/sale/order_invoices.tpl to add the second string. any ideas??
Re: Add Store logo to invoice
Posted: Tue Feb 07, 2012 2:25 pm
by natsuto
The first time a single invoice generated, then somewere otherwise you have to re-add it, if you want to print duplex invoice with store signs.
Re: Add Store logo to invoice
Posted: Wed Sep 05, 2012 4:02 pm
by Deadelus
The proper way to add your logo to the invoice while using the logo configured in the admin is as follows:
1: Edit /admin/controller/sale/order.php and add the following in the invoice() method:
Code: Select all
if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
$this->data['logo'] = HTTP_IMAGE . $this->config->get('config_logo');
} else {
$this->data['logo'] = '';
}
This reads the logo image from the config and adds the correct path to it to the invoice template.
2: Edit /admin/view/template/sale/order_invoice.tpl and add the following code before the <h1> tag:
Code: Select all
<?php if (!empty($logo)): ?>
<img src="<?php echo $logo; ?>" alt="Logo" />
<?php endif; ?>
This checks if there actually is a logo and shows the image.
Please don't add hard coded paths to your templates, it will only annoy you in the future or when you changed your logo and forgot it was hard coded in your invoice template.
Re: Add Store logo to invoice
Posted: Tue Sep 11, 2012 11:38 pm
by eesyboi
Deadelus wrote:The proper way to add your logo to the invoice while using the logo configured in the admin is as follows:
1: Edit /admin/controller/sale/order.php and add the following in the invoice() method:
Code: Select all
if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
$this->data['logo'] = HTTP_IMAGE . $this->config->get('config_logo');
} else {
$this->data['logo'] = '';
}
This reads the logo image from the config and adds the correct path to it to the invoice template.
2: Edit /admin/view/template/sale/order_invoice.tpl and add the following code before the <h1> tag:
Code: Select all
<?php if (!empty($logo)): ?>
<img src="<?php echo $logo; ?>" alt="Logo" />
<?php endif; ?>
This checks if there actually is a logo and shows the image.
Please don't add hard coded paths to your templates, it will only annoy you in the future or when you changed your logo and forgot it was hard coded in your invoice template.
Wows perfect!!!!
I was wondering how do i put the store logo inline with the heading title "INVOICE"
Re: Add Store logo to invoice
Posted: Mon Nov 26, 2012 11:36 pm
by creativecook
Hello,
I want to edit the "/admin/controller/sale/order.php" and add the code in the invoice() method:
Which line in the order.php can the invoice () method be found ?
Re: Add Store logo to invoice
Posted: Mon Dec 17, 2012 2:43 pm
by benilavie
ifyouseeks, ive done the first part but cant understand the second step, isnt it exactly the same file?
Thanks
Leisa
Re: Add Store logo to invoice
Posted: Tue Jan 08, 2013 2:20 am
by i2Paq
benilavie wrote:ifyouseeks, ive done the first part but cant understand the second step, isnt it exactly the same file?
Thanks
Leisa
NO!
The second file in the /admin/view/template/sale/order_invoice.tpl
Works like a charme, thanks!
Re: Add Store logo to invoice
Posted: Tue Apr 02, 2013 12:43 am
by Dagged
Deadelus wrote:The proper way to add your logo to the invoice while using the logo configured in the admin is as follows:
1: Edit /admin/controller/sale/order.php and add the following in the invoice() method:
Code: Select all
if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
$this->data['logo'] = HTTP_IMAGE . $this->config->get('config_logo');
} else {
$this->data['logo'] = '';
}
This reads the logo image from the config and adds the correct path to it to the invoice template.
2: Edit /admin/view/template/sale/order_invoice.tpl and add the following code before the <h1> tag:
Code: Select all
<?php if (!empty($logo)): ?>
<img src="<?php echo $logo; ?>" alt="Logo" />
<?php endif; ?>
This checks if there actually is a logo and shows the image.
Please don't add hard coded paths to your templates, it will only annoy you in the future or when you changed your logo and forgot it was hard coded in your invoice template.
Just let you know that this method works like charm with my 1.5.1.3
Re: Add Store logo to invoice
Posted: Tue Apr 16, 2013 2:38 pm
by Sebcart
Deadelus wrote:The proper way to add your logo to the invoice while using the logo configured in the admin is as follows:
1: Edit /admin/controller/sale/order.php and add the following in the invoice() method:
Code: Select all
if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
$this->data['logo'] = HTTP_IMAGE . $this->config->get('config_logo');
} else {
$this->data['logo'] = '';
}
This reads the logo image from the config and adds the correct path to it to the invoice template.
2: Edit /admin/view/template/sale/order_invoice.tpl and add the following code before the <h1> tag:
Code: Select all
<?php if (!empty($logo)): ?>
<img src="<?php echo $logo; ?>" alt="Logo" />
<?php endif; ?>
This checks if there actually is a logo and shows the image.
Please don't add hard coded paths to your templates, it will only annoy you in the future or when you changed your logo and forgot it was hard coded in your invoice template.
And it works in 1.5.5.1 - but fucked me up for a moment, until I realized everything is https in my shop.. So if you use SSL you might want to change HTTP_IMAGE in HTTPS_IMAGE and your good.
Re: Add Store logo to invoice
Posted: Tue Apr 23, 2013 2:36 pm
by shanni73
Hi
Does this add the logo to the invoice when admin are in the orders section and you click on "Print Invoice" ?
I tried it out but cant get it to work unless I have the wrong code open. Can you tell me exactly where to add it in please, when you say invoice() method, please ellaborate for me:)
Cheers
Re: Add Store logo to invoice
Posted: Tue Apr 23, 2013 11:14 pm
by Sebcart
shanni73 wrote:Hi
Does this add the logo to the invoice when admin are in the orders section and you click on "Print Invoice" ?
I tried it out but cant get it to work unless I have the wrong code open. Can you tell me exactly where to add it in please, when you say invoice() method, please ellaborate for me:)
Cheers
the invoice() method is on line 2340 of the order.php file.. the line actually states:
I didn't get it at first too but I just searched the file for invoice() and assumed this was the one

Re: Add Store logo to invoice
Posted: Sun Apr 28, 2013 7:59 pm
by shanni73
Sebcart wrote:shanni73 wrote:Hi
Does this add the logo to the invoice when admin are in the orders section and you click on "Print Invoice" ?
I tried it out but cant get it to work unless I have the wrong code open. Can you tell me exactly where to add it in please, when you say invoice() method, please ellaborate for me:)
Cheers
the invoice() method is on line 2340 of the order.php file.. the line actually states:
I didn't get it at first too but I just searched the file for invoice() and assumed this was the one

Hi again.
Thanks for getting back to me on this, Im still somewhat confused, sorry to be a real pain.
But where to I add the above code, is it in between () or somewhere outside of it? Before or after.... Ihave tried different things but noe is actually working. So I thought to ask further.
Thanks again
Re: Add Store logo to invoice
Posted: Mon Apr 29, 2013 10:59 pm
by shanni73
Hi
Is there anyone who can help me with this please? I really would like to know how to add a logo to the invoices via the admin area. When viewing the history area and you press the PRINT button, NO LOGO displays. This is also in the emails on for returns and when you update a order, NO logo goes with the emails??
I would have thought this would be something that should be normal, but for some reason it is not in OC.
Any detailed direction would be appreciated.
Thanks
Re: Add Store logo to invoice
Posted: Thu May 02, 2013 11:31 pm
by Sebcart
It should look like this:
Code: Select all
public function invoice() {
if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
$this->data['logo'] = HTTP_IMAGE . $this->config->get('config_logo');
} else {
$this->data['logo'] = '';
}
or if you have a secure SSL site:
Code: Select all
public function invoice() {
if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
$this->data['logo'] = HTTPS_IMAGE . $this->config->get('config_logo');
} else {
$this->data['logo'] = '';
}
Re: Add Store logo to invoice
Posted: Tue Aug 06, 2013 7:00 am
by Patrikiden
Hello, i'v got this working. But i would also like to have the same function for customers. So when a logedin Customer goes to Order history and click the print button (also a addon script) then the Logo should be at the top of the printed out Order information. Any idea?
Thank you.
Re: Add Store logo to invoice
Posted: Tue Aug 20, 2013 1:38 pm
by appaji
Thank you "ifyouseek". It worked for me also..
Re: Add Store logo to invoice
Posted: Fri Aug 30, 2013 5:40 am
by philipeft
Hi,
I tried this but it didnt work for me in version 1.5.6
I got the error... Notice: Use of undefined constant HTTPS_IMAGE - assumed 'HTTPS_IMAGE' in /home/sites/phoenixeft.co.uk/public_html/store3/admin/controller/sale/order.php on line 2354
I tried using HTTP and HTTPS in the code - with the same result.
I added the code snippet on the next line after the... Invoice() { in the file.
Code was... (with line numbers added after)
Code: Select all
2353 if ($this->config->get('config_logo') && file_exists(DIR_IMAGE . $this->config->get('config_logo'))) {
2354 $this->data['logo'] = HTTP_IMAGE . $this->config->get('config_logo');
2355 } else {
2356 $this->data['logo'] = '';
2357 }
I do have a store logo set up on the system, which displays ok on the front-end.
Any ideas anyone?
Thanks!
Philip.
Re: Add Store logo to invoice
Posted: Tue Oct 22, 2013 4:16 am
by TAC
Do we still have to do this in 1.5.x?