tags:

views:

237

answers:

1

Im using the XFBML version of the Like button but the "Share it" box with the space to leave a comment doesn't show up after clicking "Recommend". The rest works fine.

Im using this code:

<fb:like href="www.google.cl" width="300" action="recommend" font="lucida grande"></fb:like>

And, in the end of the page

</body>

<div id="fb-root"></div>
<script src="http://connect.facebook.net/en_US/all.js"&gt;&lt;/script&gt;
<script>
  FB.init({appId: '1234567890', status: true, cookie: true, xfbml: true});
  FB.Event.subscribe('auth.sessionChange', function(response) {
    if (response.session) {
      // A user has logged in, and a new cookie has been saved
    } else {
      // The user has logged out, and the cookie has been cleared
    }
  });
</script>    
</html>

Do you know what is happening? Any advice is warmly received. Thanks

A: 

not too long ago I was helping a friend with this and the issue on his end was the absence of meta tags required for url sharing: http://wiki.developers.facebook.com/index.php/Facebook_Share/Specifying_Meta_Tags

(the thumbnail image for the link is optional)

However, I'm not sure if you can combine the Like and Share functionality into one button with just the [x]fbml. you might want to implement a share functionality with onclick on the Like button. in onclick you would run a javascript SDK command using fb.ui with stream.share See the second example on page http://developers.facebook.com/docs/reference/javascript/FB.ui

Meta tags are needed either way.

Let me know if that gets you going in the right direction or if you get stuck again.

Raine
Thank you Raine, but still doesn't work // You can see the page in http://bit.ly/d4EDIp // Im trying to do the same as in the official example in http://bit.ly/d6kyL8 with the pop up box asking to add a comment after "like" was pushed. In that same page it reads "The XFBML version allows users to add a comment to their like as it is posted back to Facebook." // Please can you help? Im very stucked with this!
Victor P
I found this some place else in here. Quote: "You need to make sure that the "connect url" for your appid matches the domain you're putting the like button on. To do this, go to the "Edit Settings" page, and in the "Connect" section of the settings, fill on your "Connect URL".Facebook's documentation never mentions this."Also make sure you are using the correct app_id and uncheck the sandbox mode.Let me know if that worked
Raine
also, if it fails, I would try adding FB.XFBML.parse(); after FB.init() http://developers.facebook.com/docs/reference/javascript/FB.XFBML.parse
Raine

related questions