name description caption don't appear in the wall post - facebook

using Facebook Javascript SDK (since FBml doesn't work anymore), posting to a wall using my facebook app does not display name, description and caption at all. I tried adding a link and display, removed description as well, none seems to fix the issue.
Any help or note on this is helpful.
var description = $(this).parent().parent().children('.description').html();
var name = $(this).parent().parent().children('.name').html();
FB.ui(
{
method: 'feed',
attachment:
{
name: name,
caption: 'Test App',
description: description,
link: appLink,
href: appLink
},
action_links:
[
{ text: 'Test App', href: 'appLink' }
]
},
function(response)
{
if (response && response.post_id)
{
alert('Post was published.');
}
else
{
alert('Post was not published.');
}
}
);

This is actually a facebook bug. I've reported it to Facebook but haven't got any feedback since December 2011 after they've confirmed it a bug and assigned medium priority. Cheers.

Related

Facebook jssdk customizes the shared feed interface. Why don't the parameters of picture work?

According to the official Facebook document,url:https://developers.facebook.com/docs/sharing/reference/feed-dialog
But the parameters in the "Deprecated Parameters" column below do not work.
Is the interface function turned off?
I hope someone can help me. Thank you.
FB.ui(
{
method: 'feed',
name: 'Facebook Dialogs',
redirect_uri:location.href,
link: location.href,
picture: 'https://pic3.zhimg.com/80/37e17fa3d5d60f9e8bcba3bdc7e7dc06_hd.jpg',
caption: 'Reference Documentation',
description: 'tDialogs provide a simple.',
message: 'tFacebook Dialogs are easy!'
},
function(response) {
if (response && response.post_id) {
console.log(response)
alert('Post was published.');
} else {
alert('Post was not published.');
}
}
);
But the parameters in the "Deprecated Parameters" column below do not work.
That is why they are in the deprecated section (deprecated means "old" or "gone"), they don´t work anymore since a very long time. You have to provide that data with Open Graph tags in the source of the shared URLs.
More information about Open Graph tags: https://developers.facebook.com/docs/sharing/webmasters/#markup

Facebook App Stream_publish

I'm trying to make my facebook application autopost to a wall after they have accepted the permissions, ived tryied alot of things but i just cant get it working.
This is one of the things ived tryid:
FB.ui(
{
method: 'feed',
to: friendId,
name: 'title',
link: 'http://host.com/title_link.com',
picture: 'http://host.com/image.jpg',
description: 'description',
caption: 'caption',
},
function(response) {
// Check for a posting to wall
if (response && response.post_id) {
// do some logging
}
}
});
Is there anyone that got a sample code :)?
Maybe, your example is not working because there is one comma too much after
caption: 'caption'
.

Facebook C# SDK version 5.2.1 sample code to post to User wall

I am using Facebook C# SDK version 5.2.1 in Iframe App. I want to post something like images, links or videos to User Wall.
Is it possible to do the same using javascript SDK?
Please refer some sample codes or links that i can use for C# or javascript SDK..
https://developers.facebook.com/docs/reference/javascript/
FB.ui(
{
method: 'feed',
message: 'getting educated about Facebook Connect',
name: 'Connect',
caption: 'The Facebook Connect JavaScript SDK',
description: (
'A small JavaScript library that allows you to harness ' +
'the power of Facebook, bringing the user\'s identity, ' +
'social graph and distribution power to your site.'
),
link: 'http://www.fbrell.com/',
picture: 'http://www.fbrell.com/f8.jpg',
actions: [
{ name: 'fbrell', link: 'http://www.fbrell.com/' }
],
user_message_prompt: 'Share your thoughts about RELL'
},
function(response) {
if (response && response.post_id) {
alert('Post was published.');
} else {
alert('Post was not published.');
}
}
);

Publising some thing to facebook friends feeds

Salam, Hi and Hello,
I am using FB.ui method of Facebook Javascript SDK and it says, "post to your wall", I want to publish story on facebook friend's wall or in feeds. So is it possible to post story on friends feeds other than your own wall? If yes then how? I doubt that it was only possible in depreciated libraries?
I am currently using following code:
FB.ui({'method': 'stream.publish',
'from':from_user_id,
'display':'iframe',
'attachment':attachment,
'description': '',
'message': message,
'user_prompt_message': "Personailze Message",
'action_links': [
{ text: 'AppName', href: canvasURL }
]
},
function(response){
});
A Dialog is appearing but it says, "Post to Your Wall"
But What I want is that it say post to Your wall and Your Friends Home Page? as here:
http://thinkdiff.net/facebook/graph-api-iframe-base-facebook-application-development/
I followed this tutorial but it is still saying: "Post to Your Wall"
So is there any clue? That How can I achieve the intended functionality? Waiting for your response.
thanks in advance
thanks
If you want to post on any friends wall you have to add the friends id so it'll look like this
FB.ui(
{
method: 'feed',
name: 'NAME',
link: 'LINK OF THE WEBSITE OR PAGE',
picture: 'IMAGE_URL IF YOU NEED IT',
caption: 'Reference Documentation',
description: "DESCRIPTION",
to:FRIENDS_ID
},
function(response) {
if (response && response.post_id) {
alert('Post was published.');
} else {
alert('Post was not published.');
}
}
);

Simple FB.ui Dialog

I have a fb.ui modal popup on my page to let users update their status on my page. It works great so far. Now i tested and it seems to be that the postpicture, title and description are automatically pulled from my page - I didn't define them in my script. It doesn't look very nice to be honest, and i would like to remove that for my users benetit, because it looks like they are directly advertising my page. Is there any way to have the fb.ui dialog in a simple way, only that their message will be published?
Thanks for all your kind help!
EDIT: MY CODE
FB.ui(
{
method: 'feed',
message: 'Facebook Dialogs are easy!'
},
function(response) {
if (response && response.post_id) {
alert('Post was published.');
} else {
alert('Post was not published.');
}
}
);
Check the fb.ui feed page for a list of parameters being passed:
https://developers.facebook.com/docs/reference/dialogs/feed/
Some options like name, description and image will be generated automatically based on your page content, you can set them to an empty string or something more appropriate from within your code.
FB.ui(
{
method: 'feed',
message: 'Facebook Dialogs are easy!',
description: '',
name: '',
picture: _some_default_picture_
},
function(response) {
if (response && response.post_id) {
alert('Post was published.');
} else {
alert('Post was not published.');
}
}
);