- Posts: 16
- Thank you received: 0
Adding an image to attachinvoice
- rossdesigns
-
Topic Author
- Offline
I have used the following in the invoice.php of attachinvoice:
<img src=" www.dingospirit.net/images/invoice/Dingo_logo_rego_200.jpg"/ >
This results in the invoice not being attached to the order_status_notification email when the order is changed to confirmed.
Without the <img src=.../> the invoice is attached to the confirmation email.
PS. I am using Joomla! version, 2.5.7
Please log in or register to see it.
Thanks,
Geoff
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
- rossdesigns
-
Topic Author
- Offline
- Posts: 16
- Thank you received: 0
Geoff
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
- rossdesigns
-
Topic Author
- Offline
- Posts: 16
- Thank you received: 0
Unfortunately removing the back-slash has not fixed the problem either.
I had thought the problem might be linked to the fact that I'm using Joomla 2.5. I have read somewhere else on the forum that Hikashop is having some problems with linking data in the order_status_notification email. But I have managed to add the logo image to the order_status_notification email using:
<img src="images/invoice/Dingo_logo_rego_200.jpg"/>
Has anyone else placed an image on the attachinvoice?
Thanks,
Geoff
Please Log in or Create an account to join the conversation.
If there is no image, then the invoice attaches to the confirmed email. With an image, there is no attachment.
Please Log in or Create an account to join the conversation.
I just got it to work, but I used the full url of the image including http: //www infront
(no spaces, it just won't let me type it in the forum)
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
- Posts: 154
- Thank you received: 4
i am using the full url like this:
<img src=" subdomain.domain.de/templates/templatename/images/logo.svg " alt="logo" height="100" width="120">
but getting still the following error:
6 ERROR n°6 : Impossible to load the image subdomain.domain.de/templates/templatename/images/logo.svg
(EDIT: in both URLs the h t t p : / / is of course included, it has been somehow stripped off this post...)
any idea what the trouble could be?
any help appreciated...
PS.
-- HikaShop version -- : 2.3.2
-- Joomla version -- : 3.3.0
Please Log in or Create an account to join the conversation.
As explained in the previous post, you have ot put a relative path, you should put an url (so, no domain name).
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Please Log in or Create an account to join the conversation.
- Posts: 154
- Thank you received: 4
Yes, you need to enter the full URL of the image as the PDF generation library that we're using cannot handle relative links.
please clarify...
...put an url (so, no domain name)... ???
AFAIK a domain name is part of an URL
BTW: i tried also the following both
"/templates/templatename/images/logo.svg"
"templates/templatename/images/logo.svg"
i always get ERROR n°6 : Impossible to load the image h t t p : / / subdomain.domain.tld/templates/templatename/images/logo.svg
Please Log in or Create an account to join the conversation.
The problem here is not the path of the image but the fact that you're trying to use a SVG image.
The version of TCPDF used by the plugin doesn't support SVG img tags properly as far as I can see.
Try to include it manually with the ImageSVG function as shown in this example:
www.tcpdf.org/examples/example_058.phps
Please Log in or Create an account to join the conversation.
- Posts: 154
- Thank you received: 4
SVG:
...also tried all combinations without the slash at the end, ...width="120"> because i read somewhere in your forum this might cause trouble = again, it doesnt work either...
so i can say it is not due to the fact that i was trying to use a SVG...
any idea?
Please Log in or Create an account to join the conversation.
For the URL, you need to make sure that the allow_url_fopen parameter of your php.ini is activated so that the images can be retrieved.
Also, what you can try is to enter the full path of the file on your web server. Something like that : /home/user/var/www/templates/templatename/images/logo.png
Please Log in or Create an account to join the conversation.
- Posts: 154
- Thank you received: 4
the /home/user/var/www/templates/templatename/images/logo.png did not work...
i tired to use it like this:
<img src="/home/user/var/www/templates/templatename/images/logo.png" />
because this didnt work i tried also this
<img src="home/user/var/www/templates/templatename/images/logo.png" />
and this
<img src=" subdomain.domain.tld/home/user/var/www/t...name/images/logo.png " />
(of course i changed in both cases "/home/user/var/www/" by the value i can see in joomla>system information>configuration file>log_path : ...obviously without "logs" at the end!
did a make a mistake???
tomorrow i can check if i can enable allow_url_fopen on the server, but only if it is possible to set allow_url_include to OFF!
Please Log in or Create an account to join the conversation.
Lets see with the normal URL subdomain.domain.tld/templates/templatename/images/logo.png and the allow_url_fopen option activated (you have have the other turned off of course).
Please Log in or Create an account to join the conversation.
- Posts: 154
- Thank you received: 4
for anyone interested as short summary of how i got this to work:
-- HikaShop version -- : 2.3.2
-- Joomla version -- : 3.3.0
-- changed allow_url_fopen from OFF to ON
(add the line allow_url_fopen = On inside a php5.ini and save it in root)
ATTENTION!!! = for security reasons, be aware that allow_url_include should be set to OFF!!! (this should be the standard setting)
-- inside plugins/hikashop/attachinvoice/attachinvoice/invoice.php i used a relative path:
-- SVG unfortunately does not work, but nicolas posted a workaround i havent checked yet...
Please Log in or Create an account to join the conversation.