- Posts: 107
- Thank you received: 8
Order Creation Notification email image display
12 years 5 months ago #153356
by bmm01
Order Creation Notification email image display was created by bmm01
-- url of the page with the problem -- :
midwest.testme.co
-- HikaShop Business version -- : 2.3.0 12 avril 2014
-- Joomla version -- : 3.2
-- PHP version -- : 5.3
-- Browser(s) name and version -- : N/A
-- Error-message(debug-mod must be tuned on) -- : N/A
-- Email client: Outlook 2010
When I force SSL in the checkout (option YES), my Order Creation Notification email does not display images as the image source path is https
Is there a solution for this? I would like to include my logo as the header image. It works fine if force SSL is set to NO but I need SSL.
Thanks and regards
Brett
-- HikaShop Business version -- : 2.3.0 12 avril 2014
-- Joomla version -- : 3.2
-- PHP version -- : 5.3
-- Browser(s) name and version -- : N/A
-- Error-message(debug-mod must be tuned on) -- : N/A
-- Email client: Outlook 2010
When I force SSL in the checkout (option YES), my Order Creation Notification email does not display images as the image source path is https
Is there a solution for this? I would like to include my logo as the header image. It works fine if force SSL is set to NO but I need SSL.
Thanks and regards
Brett
Please Log in or Create an account to join the conversation.
12 years 5 months ago #153428
by Xavier
Replied by Xavier on topic Order Creation Notification email image display
Hi,
I think that you will have to edit the email via the menu System > Emails, then in the preload part, add the code:
Just before:
To add you logo, you can easily add an img tag in the html version of the email.
I think that you will have to edit the email via the menu System > Emails, then in the preload part, add the code:
Code:
$image = str_replace('https','http',$image);
Code:
$cartProduct['PRODUCT_IMG'] = '<img src="'.$image.'" alt="" style="float:left;margin-top:3px;margin-bottom:3px;margin-right:6px;"/>';
To add you logo, you can easily add an img tag in the html version of the email.
Please Log in or Create an account to join the conversation.
12 years 5 months ago #153775
by bmm01
Replied by bmm01 on topic Order Creation Notification email image display
Thanks Xavier
I tried this but it is not working.
I changed the Pre-load code to:
if(!empty($item->images[0]->file_path) && $config->get('thumbnail', 1) != 0) {
$img = $imageHelper->getThumbnail($item->images[0]->file_path, array(50, 50), array('forcesize' => true, 'scale' => 'outside'));
if($img->success) {
if(substr($img->url, 0, 3) == '../')
$image = str_replace('../', HIKASHOP_LIVE, $img->url);
else
$image = substr(HIKASHOP_LIVE, 0, strpos(HIKASHOP_LIVE, '/', 9)) . $img->url;
$image = str_replace('https','http',$image);
$cartProduct = '<img src="'.$image.'" alt="" style="float:left;margin-top:3px;margin-bottom:3px;margin-right:6px;"/>';
}
}
It's still generating the email as:
<table class="w600" style="font-family:Arial, Helvetica, sans-serif;font-size:12px;line-height:18px;margin:auto;background-color:#ebebeb;" border="0" cellspacing="0" cellpadding="0" width="600" align="center">
<tr style="line-height: 0px;">
<td class="w600" style="line-height:0px" width="600" valign="bottom">
<img class="w600" src=" midwest.testme.co/media/com_hikashop/images/mail/header.png " border="0" alt="Thanks for your order from MidWest Meats" />
</td>
</tr>
I tried this but it is not working.
I changed the Pre-load code to:
if(!empty($item->images[0]->file_path) && $config->get('thumbnail', 1) != 0) {
$img = $imageHelper->getThumbnail($item->images[0]->file_path, array(50, 50), array('forcesize' => true, 'scale' => 'outside'));
if($img->success) {
if(substr($img->url, 0, 3) == '../')
$image = str_replace('../', HIKASHOP_LIVE, $img->url);
else
$image = substr(HIKASHOP_LIVE, 0, strpos(HIKASHOP_LIVE, '/', 9)) . $img->url;
$image = str_replace('https','http',$image);
$cartProduct = '<img src="'.$image.'" alt="" style="float:left;margin-top:3px;margin-bottom:3px;margin-right:6px;"/>';
}
}
It's still generating the email as:
<table class="w600" style="font-family:Arial, Helvetica, sans-serif;font-size:12px;line-height:18px;margin:auto;background-color:#ebebeb;" border="0" cellspacing="0" cellpadding="0" width="600" align="center">
<tr style="line-height: 0px;">
<td class="w600" style="line-height:0px" width="600" valign="bottom">
<img class="w600" src=" midwest.testme.co/media/com_hikashop/images/mail/header.png " border="0" alt="Thanks for your order from MidWest Meats" />
</td>
</tr>
Please Log in or Create an account to join the conversation.
12 years 5 months ago #153849
by Xavier
Replied by Xavier on topic Order Creation Notification email image display
Hi,
Ok the modification given was for the product images, for your needs, thanks to replace:
By:
You can do this customization for each images in the emails.
Ok the modification given was for the product images, for your needs, thanks to replace:
Code:
<img class="w600" src="{VAR:LIVE_SITE}media/com_hikashop/images/mail/header.png" border="0" alt="" />
Code:
<?php $live = str_replace('https','http',HIKASHOP_LIVE); ?>
<img class="w600" src="<?php echo $live; ?>media/com_hikashop/images/mail/header.png" border="0" alt="" />
The following user(s) said Thank You: bmm01
Please Log in or Create an account to join the conversation.
12 years 5 months ago #153941
by bmm01
Replied by bmm01 on topic Order Creation Notification email image display
Hi Xavier
Fantastic - that's fixed the issue and it's looking really good now.
I added the same code for the Footer.
Thanks
Brett
Fantastic - that's fixed the issue and it's looking really good now.
I added the same code for the Footer.
Thanks
Brett
Please Log in or Create an account to join the conversation.
Time to create page: 0.180 seconds