I´m adding facebook like buttons to my wordpress-page. On single.php, for each blog post - which works fine. But I would also like to add facebook like button to the posts on the index page. I could do that, but the url retrieved is the main index page, which makes sense. Is there a way I can have multiple like buttons on my blog main page, and still make each one of them to point to the post?
Yes, you set the href
parameter for each individual like button to the post permalink. It's the data-href
attribute in the HTML version:
<div class="fb-like" data-href="http://example.com/your-blog-post" data-send="true" data-width="450" data-show-faces="true"></div>