1. Open view.phtml in app/design/frontend/default/[yourtheme]/template/catalog/product
2. Find in that file this line
($_product->getName()), 'name')
3. You will see the code above is inside the header HTML mark up. Under the header (this is the location that I want to set up. However, you are welcome to put the Like button anywhere in the page that you want), put this line of code
<?php
$url = $_product->getProductUrl()
?>
4. Then, put this Facebook Like code under it
<iframe src="http://www.facebook.com/plugins/like.php?href=<?php echo $url; ?>&layout=button_count&show_faces=true&width=450&action=like&colorscheme=light&height=21" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:450px; height:21px;" allowTransparency="true"></iframe>
Subscribe to:
Post Comments (Atom)
Google Play
Magento Talks now available in Google Play. Please download it from Here
Followers
Hit Counter
Popular Posts
Blog Archive
-
▼
2010
(16)
-
▼
October
(10)
- Magento How to Change the Favicon
- Replacing logo with swf format in Magento
- Remove the Categories and Products through PHPMyAdmin
- How to add Facebook Like button to your product page
- How to use both Horizontal and vertical Navigation...
- How to create a custom page in magento and link it...
- How to Edit the Magento Footer & Footer Links
- How to add new layout in Magento
- Moving / Removing Callouts on the left / right col...
- Magento Installation
-
▼
October
(10)
Feedjit
Subscribe via email
My Blog List
Powered by Blogger.
About Me
- Mohan Natarajan
- Chennai, Tamil Nadu, India
- Hi, this is Mohan Natarajan working as a Senior Software Engineer at DCKAP Technologies.I have completed BE Computer Science and Engineering in Ranipet Engineering College. I did my schooling in Govt Boys Hr Sec School Timiri.(Vellore Dist)
Categories
Text Widget
Pages
Mohan Natarajan Powered by Blogger
Thank you! This was incredibly helpful. I now have a facebook "like" button on every individual product page of my site. Thanks again!!
ReplyDelete