Create a Facebook App

first visit facebook and register your new app:
http://www.facebook.com/developers
configure the facebook settings to point to your server

grab the facebook php library:
http://github.com/facebook/php-sdk/tarball/master
or here:
developers.facebook.com/resources.php

upload your application’s new index.php to your server, something like this:

<? php
require_once ‘facebook.php’;
$appapikey = ‘1234’;
$appsecret = ‘1234’;
$facebook = new Facebook($appapikey, $appsecret);
$user_id = $facebook->require_login(); $html = ‘PUT YOUR HTML HERE’;
$facebook->api_client->profile_setFBML(NULL, $user_id, $html, NULL, NULL, $html);
echo ‘<br /><fb:add-section-button section=”profile” />’;
? >

it’s that simple.

references:

http://www.youtube.com/watch?v=roOYZKsN3Yg
http://www.merchantos.com/blog/makebeta/facebook/facebook-php-tutorial

Leave a Reply

You must be logged in to post a comment.