If you’re writing a Facebook application, I think you should have a look at cakePHP.
cakePHP, as you might already know, is the MVC framework for PHP. It feels a little bit like Rails, and a lot like slick PHP code.
The only thing I don’t particularly enjoy about cakePHP is that PHP has no ability to construct dynamic classes and objects. So, you have to make due with passing around data models as hashes. Not the greatest solution, but adequate. You also have to give PHP hints in some cases, again because it lacks the dynamic features of Ruby.
So what do you get in return? I like the tradeoff.
1. Solid deployment.
Sorry Rails fans, but PHP is just soooo much easier to deploy. Nearly every programmer and ISP in the world understand how to get your PHP app up and running on their servers.
2. A wealth of libraries
PHP wins hands-down when it comes to libraries. I love RubyForge and have never personally found Ruby lacking for libraries, but if I had to make a bet in this area, I would bet on PHP.
3. A cool IRC channel
I’m sure there is one for Rails too, but the cakePHP IRC channel feels very embryonic. There is an energy and excitement in there that appeals to me. Users are friendly and helpful.
So what does all this have to do with Facebook?
Facebook is little more than a web site that serves FBML. Making a Facebook app is like writing a web site plus the integration challenges of Facebook. This is offset by the fact that you don’t have to write your own user management system and friend management system — at least not at first.
Eventually though, you will want non-FB users to use your service as well. Here’s where PHP begins to pull ahead. Now you’re talking about having to write all the guts of user management, password recovery, friend lists, etc. Fortunately, there are many starting points for this kind of application already written in PHP. cakePHP makes building these pieces as easy as I have seen it.
I’m excited to use cakePHP for Facebook, and I like my odds when it comes to maintenance and extension later.
0 responses so far ↓
There are no comments yet...Kick things off by filling out the form below.
Leave a Comment