Support » Fixing WordPress » Facebook like button

  • I’m trying to add the facebook like and twitter tweet button to my theme, using the following code:

    <a href="http://twitter.com/share" class="twitter-share-button" data-text="<?php the_title(); ?>" data-count="horizontal" data-via="thecakestand">Tweet</a><script type="text/javascript" src="http://platform.twitter.com/widgets.js">
    </script><iframe src="http://www.facebook.com/plugins/like.php?href=<?php the_permalink() ?>&layout=button_count&show_faces=false&width=100&action=like&font=arial&colorscheme=light&height=21" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:100px; height:21px;" allowTransparency="true"></iframe>

    The twitter button works fine, posting <title> <url> via thecakestand. But the facebook button is causing me trouble. I want to display X likes <title> on <url> (where the title and url are different for each post) but instead I’m getting the title of the home page and the url of the home page? Any ideas?

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Facebook like button’ is closed to new replies.