Author Topic: Tutorial: How to get Facebook Like working on your Virtuemart site  (Read 110196 times)

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #60 on: June 30, 2011, 14:11:58 pm »
MY BROTHER IT FINALLY WORKS WITH THE NEW VERSION!!!

i really love you now! i dont touch it now.. :P

Fantastic!  I'm glad to hear it is working for you now.

goasutlor

  • Beginner
  • *
  • Posts: 6
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #61 on: July 04, 2011, 06:35:52 am »
Hi Kevinwood ,


First i must to say big thanks for your plugin but  i still have problem after i installed yout plugin about "error" when i press Like
Please try to survey my web at www.99closet.com in product pages such as

http://www.99closet.com/index.php/component/virtuemart/?page=shop.product_details&flypage=flypage.tpl&product_id=54&category_id=13



below is error from my page



My parameter





This is my flypage.tpl.php

Code: [Select]
<?php if( !defined'_VALID_MOS' ) && !defined'_JEXEC' ) ) die( 'Direct Access to '.basename(__FILE__).' is not allowed.' );
mm_showMyFileName(__FILE__);
 
?>


<?php echo $buttons_header // The PDF, Email and Print buttons ?>

<?php
if( $this->get_cfg'showPathway' )) {
echo "<div class=\"pathway\">$navigation_pathway</div>";
}
if( 
$this->get_cfg'product_navigation')) {
if( !empty( $previous_product )) {
echo '<a class="previous_page" href="'.$previous_product_url.'">'.shopMakeHtmlSafe($previous_product['product_name']).'</a>';
}
if( !empty( $next_product )) {
echo '<a class="next_page" href="'.$next_product_url.'">'.shopMakeHtmlSafe($next_product['product_name']).'</a>';
}
}
?>

<br style="clear:both;" />
<table border="0" style="width: 100%;">
  <tbody>
<tr>
<?php  if( $this->get_cfg('showManufacturerLink') ) { $rowspan 5; } else { $rowspan 4; } ?>
  <td width="33%" rowspan="<?php echo $rowspan?>" valign="top"><br/>
  <?php echo $product_image ?><br/><br/><?php echo $this->vmlistAdditionalImages$product_id$images ?></td>
  <td rowspan="1" colspan="2">
  <h1><?php echo $product_name ?> <?php echo $edit_link ?></h1>
  </td>
</tr>
<?php if( $this->get_cfg('showManufacturerLink')) { ?>
<tr>
  <td rowspan="1" colspan="2"><?php echo $manufacturer_link ?><br /></td>
</tr>
<?php ?>
<tr>
      <td width="33%" valign="top" align="left">
      <?php echo $product_price_lbl ?>
      <?php echo $product_price ?><br /></td>
      <td valign="top"><?php echo $product_packaging ?><br /></td>
</tr>
<tr>
  <td colspan="2"><?php echo $ask_seller ?></td>
</tr>
<tr>
  <td rowspan="1" colspan="2"><hr />
  <?php echo $product_description ?><br/>
  <span style="font-style: italic;"><?php echo $file_list ?></span>
  </td>
</tr>
<tr>
  <td><?php 
  
if( $this->get_cfg'showAvailability' )) {
   echo $product_availability
   }
   ?>
<br />
  </td>
  <td colspan="2"><br /><?php echo $addtocart ?></td>
<div id="fb-root"></div><script src="http://connect.facebook.net/en_US/all.js#appId=184732911584191&amp;xfbml=1"></script><fb:like send="true" width="450" show_faces="false" font=""></fb:like>
</tr>
<tr>
  <td colspan="3"><?php echo $product_type ?></td>
</tr>
<tr>
  <td colspan="3"><hr /><?php echo $product_reviews ?></td>
</tr>
<tr>
  <td colspan="3"><?php echo $product_reviewform ?><br /></td>
</tr>
<tr>
  <td colspan="3"><?php echo $related_products ?><br />
   </td>
</tr>
<?php if( $this->get_cfg('showVendorLink')) { ?>
<tr>
  <td colspan="3"><div style="text-align: center;"><?php echo $vendor_link ?><br /></div><br /></td>
</tr>
<?php  ?>
  </tbody>
</table>
<?php 
if( !empty( $recent_products )) { ?>

<div class="vmRecent">
<?php echo $recent_products?>
</div>
<?php 
}
if( !empty( 
$navigation_childlist )) { ?>

<?php echo $VM_LANG->_('PHPSHOP_MORE_CATEGORIES'?><br />
<?php echo $navigation_childlist ?><br style="clear:both"/>
<?php 
?>


goasutlor

  • Beginner
  • *
  • Posts: 6
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #62 on: July 04, 2011, 12:52:54 pm »
Now it work fine for me but it have a little bit problem about link in facebook page.
In facebook page can show true picture but wrong link such as

http://www.99closet.com/virtuemart?page=shop.product_details&product_id=39&flypage=flypage.tpl&option=com_virtuemart&Itemid=64

But the true link is

http://www.99closet.com/index.php?page=shop.product_details&product_id=39&flypage=flypage.tpl&option=com_virtuemart&Itemid=64


Please suggest me to correct it.

Thanks in advance.

KO

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #63 on: July 04, 2011, 14:19:40 pm »
What version of vm open graph are you using?

goasutlor

  • Beginner
  • *
  • Posts: 6
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #64 on: July 04, 2011, 18:14:12 pm »
plg_vmopengraph_1.8
plg_vmaddcanonical_1.2

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #65 on: July 04, 2011, 19:08:26 pm »
Hmmm.... weird.  This is a new one on me.  You appear to have Joomla SEF turned on, but without URL re-writing, is that correct?  What other extensions do you have installed?

goasutlor

  • Beginner
  • *
  • Posts: 6
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #66 on: July 05, 2011, 04:24:07 am »
After i installed " TagMeta1.3Community " i will face the problem.. But now i've uninstall this mod so it still have problem

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #67 on: July 06, 2011, 14:08:36 pm »
Please try VM Open Graph 1.9 and see if that makes any difference.  I had uploaded it to JoomlaCode a week or so ago but forgot to tick the "released" option.  You can get it here:
http://joomlacode.org/gf/project/vmopengraph/frs/


goasutlor

  • Beginner
  • *
  • Posts: 6
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #68 on: July 06, 2011, 17:24:20 pm »
Still have same problem after i installed new version of your plugin


http://www.99closet.com/virtuemart?page=shop.product_details&product_id=39&flypage=flypage.tpl&option=com_virtuemart&Itemid=64

But the true link is

http://www.99closet.com/index.php?page=shop.product_details&product_id=39&flypage=flypage.tpl&option=com_virtuemart&Itemid=64

But when I try to checl Enable the Cookie Check? It will be the true link but it will have "error" behine " like this"

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #69 on: July 06, 2011, 20:49:29 pm »
Well, I just went to your store again and it seems to be working perfectly.  What did you do to fix it?

goasutlor

  • Beginner
  • *
  • Posts: 6
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #70 on: July 07, 2011, 06:21:38 am »
it doesn't work for me but i want to say thank you  for your nice support. Now i remove this tag from my pages already.

Thanks.

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #71 on: July 07, 2011, 14:14:33 pm »
Well, as I said I just tried it on your site yesterday and it worked perfectly!

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #72 on: July 12, 2011, 14:05:54 pm »
Yeah, that's a weird one.  Have you tried unchecking the "browser cookie check"?

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #73 on: July 12, 2011, 18:14:46 pm »
I just tried about 5 of your products and it worked fine on 4 of them (including the one you posted above) but failed on 1.  However, I can't see any reason why that one product failed.  It doesn't produce any sort of error message.

This is the one that failed:
[link removed by request]

Try one thing for me... in the VM Open Graph config, disable the "og:url" tag and then try it again.

kevinwood

  • Jr. Member
  • **
  • Posts: 151
Re: Tutorial: How to get Facebook Like working on your Virtuemart site
« Reply #74 on: July 12, 2011, 22:30:11 pm »
Hi Kevin, thanks , I disabled it , what "the og:url tag" is for?

I also moved the script little up.

Can you please check it from your side?

Thank you very much.

The og:url tag tells FB what the canonical URL for the product page should be.  It's redundant if you already have a rel-canonical tag.

Anyway, I've figured out what the problem is with your site.  When I view the site with Chrome, I can see that for those pages where it wasn't working before, the "Like" button changes to a "Confirm" button when clicked, and then when you click on the confirm button it tries to open a pop-up window asking you to confirm the Like.  If you do so, it works properly and posts the item to your wall.  Apparently this is some security feature that Facebook added to try to prevent clickjacking.  For whatever reason, Facebook thinks that your site may be spammy and so it tries to pop up this window on some of your pages.

Of course, it fails if you have a popup blocker turned on (which almost everyone does!).  Even worse, the 'confirm' button seems to be hidden more often than not (I only see it in Chrome but not in Firefox)  In fact, there is a long thread of complaints about this from other sites on the Facebook developer site:
http://forum.developers.facebook.net/viewtopic.php?id=93201&p=1

So the "good" news is that your site is configured properly and the plugins are working properly.  The bad news is that there doesn't appear to be a solution.  Since most of your pages do not appear affected, I would recommend leaving well enough alone and hopefully Facebook will figure out what your site isn't spammy and will stop requiring this confirmation.