Facebook Application Development PHP SDK 3.1.1

Facebook is going to upgrade Developer API by 1st October 2011. All sites and apps on Facebook will migrate to OAuth 2.0 through this update. This will ensure that users browsing Facebook over HTTPS will have a great experience over a secure connection. We can imagine that these changes will make facebook better and more … Read more

Exceptions with Facebook Apps

OAuthException: Error validating access token: Session has expired at unix time 1311357600. The current unix time is 1311357734 Request FB Access Token each & every time… Rotate Apps… OAuthException: (#1) An unknown error occurred Sometime facebook block App’s domain and text, images, links etc. used on apps, You can use URL Linter to cross check … Read more

iWishYou – My Best Wishes with MP3 on Facebook

iWishYou is a facebook application where you can share Wishes / Greeting as songs for friend’s birthday, events, daily wishes. A wish is a hope or desire for something, iWishYou attract users with nice share on FB Walls. It is the better way to express your emotions to your friends & circle.

Get PID from FBID

<?php include(“lib/facebook.php”); $APPLICATION_ID = “xxxxxxxxxxxxxxx”; $APPLICATION_SECRET = “yyyyyyyyyyyyyyyyyyyyyyyyyyyy”; $facebook = new Facebook(array( ‘appId’ => $APPLICATION_ID, ‘secret’ => $APPLICATION_SECRET, ‘cookie’ => true )); $fbid=”xxxxxxxxxx”; $fql = “SELECT pid FROM photo WHERE object_id=”.$fbid; $param = array(  ‘method’ => ‘fql.query’,  ‘query’ => $fql,  ‘callback’ => ” ); $fqlResult = $facebook->api($param); $fql = “SELECT src_small, src_big FROM photo WHERE … Read more

Save Facebook Profile Photo

<?php $facebook_uid = ‘100000296428149’; $sourcecode = save_facebook_profile_photo($facebook_uid); print_r($sourcecode); file_put_contents(“images/”.$facebook_uid.”.jpg”, file_get_contents($sourcecode[‘url’])); //this is name of new file that i save function save_facebook_profile_photo( $id ) {     $options = array(         CURLOPT_RETURNTRANSFER => true, // return web page         CURLOPT_HEADER => false, // don’t return headers         CURLOPT_FOLLOWLOCATION => true, // follow redirects         CURLOPT_ENCODING => “”, // handle all encodings         CURLOPT_USERAGENT … Read more

Amazon S3 & Facebook Fanpage app

I want to link Amazon S3 https object like “https://s3.amazonaws.com/bucket/index.html” to facebook iframed fan page… But it returned error…. 405 Method Not Allowed Code: MethodNotAllowed Message: The specified method is not allowed against this resource. ResourceType: OBJECT Method: POST RequestId: XXXXXXXXXXXXX HostId: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX OR PreconditionFailedAt least one of the pre-conditions you specified did not holdBucket … Read more

How to check Facebook Application is Alive or Dead?

<?php include(“facebook.php”); $APPLICATION_ID = “”; $APPLICATION_SECRET = “”; $facebook = new Facebook(array( ‘appId’ => $APPLICATION_ID, ‘secret’ => $APPLICATION_SECRET, ‘cookie’ => true )); $fql = “SELECT api_key FROM application WHERE app_id=” . $APPLICATION_ID; $param = array(  ‘method’ => ‘fql.query’,  ‘query’ => $fql,  ‘callback’ => ” ); $fqlResult = $facebook->api($param); if(isset($fqlResult[0][‘api_key’]) && $fqlResult[0][‘api_key’]!=””)   echo “This app is … Read more

Image Map in FBML

Facebook FBML application does not support hotspots in an image map using dreamweaver. <div style=”position: relative;”> <!– Hot Spots – Image Map –> <div id=”svnlabs1″ style=”background: none repeat scroll 0% 0% transparent; cursor: pointer; outline: medium none; text-align: center; vertical-align: middle; position: absolute; top: 72px; left: 460px; z-index: 99; padding: 10px;”></div> <div id=”svnlabs2″ style=”background: none repeat … Read more