Post by elharery » Tue Oct 14, 2014 5:51 am

when i share product the image is not appearing, is there any solution!

Newbie

Posts

Joined
Tue Oct 14, 2014 5:37 am

Post by tacobandito » Wed Oct 15, 2014 12:48 am

My recommendation would be to add the following code to the header.tpl file , located at catalog\view\theme\YOUR_THEME\template\common\header.tpl

Search for this code...

Code: Select all

<meta charset="UTF-8" />
Add this below it...

Code: Select all

<?php 
if ( isset($thumb) && !empty($thumb) ) {
echo "<meta property='og:image' content=' ".$thumb." '/> ";
} 
?>
This should only add the appropriate metatag if you're on a product page (where an appropriate thumbnail is available). Depending on your theme, you should be aware of this note...

Please use an image that's at least 200x200 and preferably 1500x1500.

...default for OpenCart is above 200x200, but you may need to adjust as appropriate.

[module] PayPal Pro w/Recurring Profiles FREE
[module] 1 Click "Amazon Style" Checkout w/PayPal Pro FREE
[module] Adjustable PayPal Pro Fee FREE
[module] Add Sample To Cart LITE FREE
The guide to fixing just about everything wrong with OpenCart FREE!
Add INFINITE SCROLL to your homepage for FREE!
Live update product price for FREE!
Dynamic generation of Opencart coupon, FREE!
Hire me


User avatar
Active Member

Posts

Joined
Sat Mar 30, 2013 12:27 am
Location - Springfield, MA

Post by elharery » Sat Nov 01, 2014 8:50 am

thanks bro for the reply, but still it's not working, any other solution?

Newbie

Posts

Joined
Tue Oct 14, 2014 5:37 am
Who is online

Users browsing this forum: No registered users and 4 guests