No need for a plugin to put the Facebook Like button on your posts. Paste this where you want the button in your single.php or post.php depending on the theme you’re using:
<iframe src="http://www.facebook.com/plugins/like.php?
href=<?php echo urlencode(get_permalink()); ?>&layout=button_count
&show_faces=false&width=450&action=like&
font=lucida+grande&colorscheme=light&height=21"
scrolling="no" frameborder="0" style="border:none; overflow:hidden;
width:450px; height:21px;" allowTransparency="true"></iframe>
There are several settings, so if you want yours to look different than mine, generate the code here.
Then, put in
<?php echo urlencode(get_permalink()); ?>
where the URL is in the code, as I’ve done above.
(I’ve had to include carriage returns in the code above to get it to fit in the space. You might need to take them out when you paste in the code.)
Nice hack! Like it, thanks ~
Im so glad that you shared this! I had much trouble with implementing this feature cause the 2 plugins i was using were not compatible. Now i dont have to use another plug in. Thanks!
Nice – this is just a thing I really needed and couldn’t find till now.
Thanks. I just found you and your sites and reading up a storm. I can’t get enough. I’m going to put this Facebook icon on my blog or try to. I hope to spruce up my blog now that I’ve found you.
I was having a hard time with the Facebook Like plugin. However I fixed it later. This seems pretty neat. Thanks.
Thanks for this – i have been having hassles with compatibility with my facebook plugin – i will try this and let you know how it goes
Thanks
Gary
Awesome. Been looking for something like this for a minute.
Thanks! This is so helpful!
O man! Thanks for this, I have been looking for this to put it on my site, I have a facebook link, to my page, but not a like button. I will be using this, thanks a lot for the tutorial and keep up the good work on the hacks.
Hey Great post. I’ve been having so many problems implementing the FB Like button onto http://www.odaso.com (Sorry for linking). I will be try out this code and see if it works for me. fingers crossed!
Nice info thanks. Sometimes its useful to put a Like button somewhere other than where the plug ins want to put them!
thanks
Thanks for posting that. I am really interested in improving my wordpress site.
Finally someone who really know their stuff about Word Press. Thanks for the code
Can I use multiple Search engine optimization plugins for my website. I’ve all-in-one seo and google xml sitemap. But seeking to download more for the additional help. Will this have a detrimental impact on my rankings or will it help tremendously? Thanks very a lot
First of all, I am not a very avid wordpress user. I use flatpress as my blog script. No hatred for WP, its a good script.
The good thing about this nice little hack it that I believe that it can be modified for flatpress.
Thank you..
Nice ! Easy ! go ! thanks. Really helpful. already put that code on my site.
Thanks for the post. I am paranoid about adding plugins to my site and something like this would work best for me.