Reputation: 577
I have my app posting a link to the user's wall if they have given it permissions, but it ignores the picture, name, and caption values I pass along with it.
HTTParty.post("https://graph.facebook.com/#{@sponsorship.fbid}/links", :query => {:access_token => URI.escape(@access_token), :link => URI.escape(request.env['HTTP_HOST']), :picture => URI.escape("#{request.env['HTTP_HOST']}/images/fb_post/after_donation.jpg"), :name => URI.encode("Click here"), :caption => URI.encode("This is the caption")})
Any help is appreciated, thanks.
Upvotes: 0
Views: 658
Reputation: 43816
It's probably taking those values from the open graph meta tags on the link target rather than the ones you provide at post time. Not sure if that's supposed to be happening but you should check if your link has the correct tags.
https://developers.facebook.com/docs/opengraph/ is the docs and https://developers.facebook.com/tools/debug will show you what markup is detected on your page
Upvotes: 0
Reputation: 11
Think you might need to be using
https://graph.facebook.com/#{@sponsorship.fbid}/feed
instead of
https://graph.facebook.com/#{@sponsorship.fbid}/links
Upvotes: 1