Welcome back for the second installment of the Facebook Application Development Tutorial. In this post I will show you how to create a very simple PHP application for Facebook.
This tutorial requires you to have:
#1 - Web space capable of hosting PHP applications.
and
#2 - Copy of the core Facebook API files (found here: http://developers.facebook.com/clientlibs/facebook-platform.tar.gz)
First step will be to extract these files on your web host (I will show the FTP method for those of you without SSH access).
Download the Facebook API to your local computer. Using either WinRAR or WinZip, extract the archive onto your Desktop.
Next, you must now upload these files into your web space directory using your favorite FTP client. If you don’t have one, I recommend FileZilla.
Ok, great! Next thing to do is open a copy of your favorite Text Editor. For Programming I personally recommend Programmers Notepad, but regular old Notepad will work too!
Once you have your text editor open, you are going to want to download a copy of the example code from here and copy/paste this into notepad.
You will need to replace the $appapikey and $appsecret variables with your app’s keys. This can be found on the Developers page.
Save the file as index.php and upload onto your web server using your FTP client (note: this should NOT be in the facebook-platform directory. This should be in the directory CONTAINING facebook-platform).
Now you can check out your creation! Simply add the application to your profile, and you’re done! (Go to the Developer screen, select your application from the menu on your right, and click Add To Profile)
For current web developers, creation of Facebook applications couldn’t be easier.
The next installment will show you how to interface Smarty PHP template engine to save you time (Which means Money!) designing re-usable user interfaces for your applications.
Until next time..
Tags: Application Development, Facebook, Getting Started, tutorial
Recent Comments