Nicor Lengert
Nicor Lengert

Reputation: 308

facebook feed dialog with empty message not showing

I am using the facebook feed dialog to share blog posts. It works when I fill the message field with some text. But it does not share on FB when I just click on "share" leaving the message field empty.

Is this the intended behavior? Since no error messages are shown, this would be quite misleading for the user.

However, a response in generated, checked by the callback function below. Here is my code:

 function feedFB(link, image_url, name, caption, description) {
    var obj = {
      method: 'feed',
      link: link,
      picture: image_url,
      name: name,
      caption: caption,
      description: description,
    };
    function callback(response) {
        if (response && response.post_id) {
            alert('Post was published.');
        } else {
            alert('Post was not published.');
        }
    }
    FB.ui(obj, callback);

  }

Upvotes: 0

Views: 550

Answers (1)

Nicor Lengert
Nicor Lengert

Reputation: 308

Hm, already "solved". This was only happening when my app was in sandbox mode. After changing the status to live on the facebook developer page, it worked as expected. Still, this seems buggy to me.

Upvotes: 0

Related Questions