Post by Chrissy Poo » Mon Jul 19, 2010 11:19 am

Image

Requirements:
- SEO URLs Must be Enabled

Demo:
Demo Link: http://www.stylemyapple.co.uk

Instructions:

Edit the file: catalog/view/theme/default/template/product/product.tpl

Find this piece of code:

Code: Select all

</table>
            <br />
            <?php if ($display_price) { ?>
Replace the <br /> with the following:

Code: Select all

<div style="width: 100%; padding-top:10px;">
            <table>
               <tr>
              <td><iframe src="http://www.facebook.com/plugins/like.php?href=<?php echo $this->model_tool_seo_url->rewrite(HTTP_SERVER . 'index.php?route=product/product&product_id='.$this->request->get['product_id']); ?>&layout=standard&show_faces=false&width=280&action=like&colorscheme=light&height=35" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:270px; height:35px;" allowTransparency="true"></iframe>
              </td>
              </tr>
            </table>
            </div>
I have tested this on OpenCart 1.4.8b in IE6, IE7, IE8, FF 3.6.6

Let me know if you find any problems :)

10% Discount on all Shared and Reseller Hosting Packages at Vidahost.com

Discount Code: DISCOUNT10


Active Member

Posts

Joined
Mon Jun 29, 2009 8:48 am
Location - UK

Post by Signserve » Wed Jul 21, 2010 5:33 pm

Can confirm that this is an awesome script, just installed it and tested it on our store! :)

Thumbs up!

Newbie

Posts

Joined
Mon Jul 19, 2010 8:27 pm

Post by Chrissy Poo » Wed Jul 21, 2010 7:08 pm

Signserve wrote:Can confirm that this is an awesome script, just installed it and tested it on our store! :)

Thumbs up!
Glad you like :)

10% Discount on all Shared and Reseller Hosting Packages at Vidahost.com

Discount Code: DISCOUNT10


Active Member

Posts

Joined
Mon Jun 29, 2009 8:48 am
Location - UK

Post by musicofthehart » Fri Jul 23, 2010 3:03 am

VERY cool, but when I click on like it, then go to my facebook page it says... likes Product not found!

not sure what to do. Thanks for your help in advance

New member

Posts

Joined
Fri Jul 16, 2010 3:42 pm

Post by Chrissy Poo » Fri Jul 23, 2010 6:09 am

musicofthehart wrote:VERY cool, but when I click on like it, then go to my facebook page it says... likes Product not found!

not sure what to do. Thanks for your help in advance
Do you have SEO URLs enabled?

Is your site live and viewable to the public?

10% Discount on all Shared and Reseller Hosting Packages at Vidahost.com

Discount Code: DISCOUNT10


Active Member

Posts

Joined
Mon Jun 29, 2009 8:48 am
Location - UK

Post by musicofthehart » Fri Jul 23, 2010 11:55 am

I did NOT have SEO URLS enabled, I am sure that was my problem, but now I have opened up a whole new can of worms since I turned that on.... all of my pages are not found. I am sure it has to do with the fact that I am using godady hosting. Ill try to figure out this problem and get back to you. Great mod btw... and I am sure it works once I get my new problem fixed.

New member

Posts

Joined
Fri Jul 16, 2010 3:42 pm

Post by musicofthehart » Fri Jul 23, 2010 1:41 pm

All better now, the SEO URLS are enabled, and your script works great. Thank you very much for this!

New member

Posts

Joined
Fri Jul 16, 2010 3:42 pm

Post by Chrissy Poo » Sat Jul 24, 2010 1:35 am

musicofthehart wrote:All better now, the SEO URLS are enabled, and your script works great. Thank you very much for this!
No problems, glad to help :)

10% Discount on all Shared and Reseller Hosting Packages at Vidahost.com

Discount Code: DISCOUNT10


Active Member

Posts

Joined
Mon Jun 29, 2009 8:48 am
Location - UK

Post by felizone » Mon Aug 30, 2010 11:21 am

Hello,

I added to my code, but it shows error while i clicked the like button.
The page showed.
http://www.facebook.com/connect/connect ... _error.php
cannot access and cannot find item.

What's the matter?
My server problem or my code error?

Thanks,
Felix

New member

Posts

Joined
Thu Apr 08, 2010 3:28 pm

Post by Chrissy Poo » Mon Aug 30, 2010 6:09 pm

felizone wrote:Hello,

I added to my code, but it shows error while i clicked the like button.
The page showed.
http://www.facebook.com/connect/connect ... _error.php
cannot access and cannot find item.

What's the matter?
My server problem or my code error?

Thanks,
Felix
Whats the url for your store?

10% Discount on all Shared and Reseller Hosting Packages at Vidahost.com

Discount Code: DISCOUNT10


Active Member

Posts

Joined
Mon Jun 29, 2009 8:48 am
Location - UK

Post by DirtyJeeves » Tue Sep 07, 2010 11:22 pm

Great script.

Having troubles with the "likes Product Not Found" as mentioned earlier. We have SEO URLs enabled. URL is below.

Any help would be greatly appreciated.

Thanks,
Chad

(STILL IN DEVELOPMENT) http://www.onecraftymother.net

Newbie

Posts

Joined
Tue Sep 07, 2010 11:17 pm

Post by DirtyJeeves » Tue Sep 07, 2010 11:47 pm

I guess it would help to add SEO Keywords. :laugh:

I got it figured out. Again, great script!

Newbie

Posts

Joined
Tue Sep 07, 2010 11:17 pm

Post by Chrissy Poo » Wed Sep 08, 2010 1:38 am

DirtyJeeves wrote:I guess it would help to add SEO Keywords. :laugh:

I got it figured out. Again, great script!
Glad you got it sorted! Enjoy :)

10% Discount on all Shared and Reseller Hosting Packages at Vidahost.com

Discount Code: DISCOUNT10


Active Member

Posts

Joined
Mon Jun 29, 2009 8:48 am
Location - UK

Post by ifone_developer » Thu Sep 16, 2010 3:50 pm

Hi guyz,
Tanx for the code.. It works great for me.. But i have a small problem.
When i log in, and if i like a particular product, counter gets incremented by 1.
After that when i move to a new product, counter status is still 1.. It juz shows the same value as
it shows for previous product...
I guess its becuz it doesn't recognize my product id....
Here's my code..

<div style="width: 100%; padding-top:10px;">
<table>
<tr>
<td><iframe src="http://www.facebook.com/plugins/like.php?href=<?php echo $this->model_tool_seo_url->rewrite(HTTP_SERVER . 'index.php?route=product/product&product_id='.$this->request->get['product_id']); ?>&layout=box_count&show_faces=true&width=450&action=like&font=arial&colorscheme=light&height=65" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:65px;" allowTransparency="true"></iframe>
</td>
</tr>
</table>
</div>

Now what i want is , counter should be distinct for each product.
Can anyone plz tell me how to fix this??? Any ideas or code????
Tanx in advance

New member

Posts

Joined
Sat Jul 10, 2010 6:48 pm

Post by henryq30 » Sun Oct 03, 2010 11:35 am

I need help with this.
I added the code but in facebook is displayed "Product not finded". I actiivated SEO Url and added keyword to the products.

I apreciate any help.

My store is this: http://gedyan.com/new/index.php?route=common/home

Newbie

Posts

Joined
Sun Oct 03, 2010 11:20 am

Post by henryq30 » Mon Oct 04, 2010 12:57 am

Ready, it is working.
I added the file .htaccess
with this text inside:

Code: Select all

# 1.To use URL Alias you need to be running apache with mod_rewrite enabled. 

# 2. In your opencart directory rename htaccess.txt to .htaccess.

# For any support issues please visit: http://www.opencart.com

# For security reasons, Option followsymlinks cannot be overridden.
#Options +FollowSymlinks
Options +SymLinksIfOwnerMatch

RewriteEngine On
RewriteBase / 
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)\?*$ index.php?_route_=$1 [L,QSA]
Also I added SEO keywords to the products and categories

Newbie

Posts

Joined
Sun Oct 03, 2010 11:20 am

Post by FabioSwiss » Thu Oct 14, 2010 4:17 am

Does this MOD work on 1.3.2 version? Thanks!

Newbie

Posts

Joined
Fri Sep 17, 2010 4:06 am

Post by CEOself » Mon Nov 08, 2010 5:34 am

When I turn on the SEO URLs everything goes out the window. The product pages run to "Page Not Found". I have multiple SEO keywords in for each item. They are separated by commas. Any ideas of what I am doing wrong?

Newbie

Posts

Joined
Tue Dec 29, 2009 3:05 pm

Post by sketchi » Mon Nov 15, 2010 4:19 am

The Facebook Like iframe works for me (running OpenCart 1.4.9.2) but the wrong product image is displayed in my Facebook feed. Any ideas how to fix?

Edit: I think what's needed is an Open Graph meta tag with the correct image path, so I've tried entering this into header.tpl, but I don't get it to display the thumb:

Code: Select all

<?php if ($thumb) { ?>
<meta property="og:image" content="<?php echo $thumb; ?>" />
<?php } ?>

User avatar
New member

Posts

Joined
Wed Sep 22, 2010 5:04 pm

Post by leomazz » Tue Nov 16, 2010 9:35 am

Thank you so much. I worked grate to me.
How can I change the colors of the text in de IFRAME?

Thanks!

Mamma mia! Donde me meti...?


New member

Posts

Joined
Mon Jan 04, 2010 10:45 am
Location - Banfield - Buenos Aires
Who is online

Users browsing this forum: No registered users and 15 guests