Pergunta

i feel so frustrated, since i have been looking for this all day, from hundreds of sites and with my accumulated frustration i´m not making my life easier.

My problem is this.. i have made an app for facebook in php, and now i want to put a button there that when people press it, it would send a post to their time line, with the permissions and all. I have seen a lot of things and have not been able to help my self, í´m almost having a stroke with this. Can some one please help me?????

Foi útil?

Solução

Facebook has decent documentation. Besides the overall reference mentioned in the comment, start here:

https://developers.facebook.com/docs/php/gettingstarted/ https://developers.facebook.com/docs/php/howto/postwithgraphapi

Be sure to create a Facebook app to get the App ID that you'll need to configure the Facebook object.

The part of the code that does the actual post is this:

$facebook->api('/me/feed', 'POST',
  array(
    'link' => 'www.example.com',
    'message' => 'Posting with the PHP SDK!'

));

I know you mentioned doing this with PHP. I have created similar functionality in a PHP app (post to a user's wall when clicking a button), but I used the Javascript API, so it's invoked client-side. There is similar documentation for the Javascript API by Facebook. Just a thought.

If you are getting specific errors, please post them and you'll get more specific answers.

Outras dicas

i was able to do something similar to what i wanted with the search parameters from the help you provided.

I found this tutorial and with a little tweaking i managed to do something. I will leave the link to the tutorial below so it can help some one in the future.

http://25labs.com/tutorial-integrate-facebook-connect-to-your-website-using-php-sdk-v-3-x-x-which-uses-graph-api/

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top