Auto Post on Facebook with PHP
Created by: Dr.Ferrous
click here to download the Facebook PHP SDK
Sign in to your Facebook account and go to this link: https://developers.facebook.com/apps
If this is the first time you create an app, you'll see this:
Once you click on "Send as Text", Facebook will send you an SMS containing a code, put that code in the text box "Confirmation code"
And hit Register, and you'll be redirected to quickstart url.
Click on WWW.
Type in your app name, for example "Roberto Carlos" and click on "Create New Facebook App ID" and then fill the required fields.
You'll be asked to put your website that will use the Facebook SDK.
Now go back to this link https://developers.facebook.com/apps/ and click on your app.
Go to App Review tap and turn on the switch button to make it public.
Go to the dashboard and copy App ID & App Secret and put them somewhere because you'll need them later.
Replace App_ID with your app's id and open it:
You'll be redirected to the redirect_uri which is (in this example) phpwin.org, and the address will be like this:
http://www.phpwin.org/?code=AQDLYoaBucZ5C23C9ReR... very long
copy the long code and put it in this url with app Secret & App ID then open it:
Now Copy your access token because you'll need it.
Now In order to publish a post in your page, you must get the pages's ID
Put your previously generated access token in this link and open it:
you'll see something like this:
copy the page's ID and put them in
Extract Facebook SDK and create a php file, for example