Facebook Like, Share and Add this pop up menu
I have edited the file slightly and pasted the code into a different location on the product page (My product image would not display if the code was pasted above the image in ie8)
Used with Zen Cart 1.3.8a.
Edited and working in heavily customised site http://www.digitaleasy.co.nz/ecommer...oducts_id=5769
Not tested in 1.3.9 since It may not work with Facebook Like button links.
If you're using SEO links you'll have to edit the Facebook Like button below to
Code:
<iframe src="http://www.facebook.com/plugins/like.php?href=<?php echo zen_href_link(zen_get_info_page((int)$_GET['products_id']),'cPath= '.(int)$_GET['cPath'].' &products_id=' . (int)$_GET['products_id']); ?>&layout=button_count&show_faces=false&width=80&action=like&font=arial&colorscheme=light&height=35" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:80px; height:35px"></iframe>
1. Backup includes\templates\template_default\templates\tpl_product_info_display.php and COPY it to includes\templates\YOUR_TEMPLATE\templates\tpl_product_info_display.php edit the file in YOUR_TEMPLATE and no other, keeping the template_default intact as backup.
2. Here's the code with comments. Read them and edit as needed. You do NOT need to edit other files.
Code:
<!--bof Socialize -->
<style type="text/css">
div.share {float: right; }
div.share ul {float:right; list-style-type:none; padding:0;}
div.share li {float:left; display:inline; padding:0 5px;}
</style>
<div class="share">
<ul>
<li>
<a name="fb_share" type="button" href="http://www.facebook.com/sharer.php">Share</a><script src="http://static.ak.fbcdn.net/connect.php/js/FB.Share" type="text/javascript"></script> <!-- seperate Facebook share button -->
</li>
<li>
<iframe src="http://www.facebook.com/plugins/like.php?href=<?php echo urlencode(zen_href_link(zen_get_info_page((int)$_GET['products_id']),'cPath='.(int)$_GET['cPath'].'&products_id=' . (int)$_GET['products_id'])); ?>&layout=button_count&show_faces=false&width=80&action=like&font=arial&colorscheme=light&height=35" scrolling="no" frameborder="0" allowTransparency="true" style="border:none; overflow:hidden; width:80px; height:35px"></iframe> <!-- Facebook button_count Like button using standard Zen Cart product links -->
</li>
<li>
<span class="addthis_toolbox addthis_default_style"> <!-- simple www.addthis.com expandable button. Register to get statistics and edit USERNAME. Remove the img src tag to use addthis standard icon -->
<a href="http://www.addthis.com/bookmark.php?v=250&username=USERNAME" class="addthis_button_compact">
More</a>
</span>
<script type="text/javascript" src="http://s7.addthis.com/js/250/addthis_widget.js#username=USERNAME"></script>
</li>
</ul>
</div>
<!--eof Socialize -->
3. Edit includes\templates\YOUR_TEMPLATE\templates\tpl_product_info_display.php
Copy and paste code after <!--eof Main Product Image-->
Get a Social Media on!
Hack by Colin S)
Original code by scrap
Bookmarks