CodeIgniter on the Command-Line

Credit: http://www.flickr.com/photos/ripton/So, yesterday, I spent a few hours trying to create a robust command-line interface for one of my CodeIgniter applications.  I learned a lot about PHP-CLI.  I also came to remember why it’s a bad idea to try and fit a round peg in a square hole.

The thing is, CodeIgniter is a great little web framework.  See the key word in that sentence?  Yes, you can hack some CLI functionality in, but if you want to start doing fancy stuff like adding multiple levels of interactive menus and such, then its time to rethink what you’re doing.

On the other hand, there are many reasons to create a simple CLI-interface to your web application.  The main use would be for running of maintenance tasks and automated CRON scripts.  For this kind of task, it’s very easy to create a CLI entry-point for your app.

Read more

Playing with Asynchronous PHP Processing

Picture Credit: konszvi at FlickrA subject that has intrigued me lately is this topic of asynchronous PHP processing.  The idea is you have a web application that includes a task which takes a long time, like, say processing video files or sending mass emails.  Your users should be able to click a button, get a notification that their job is waiting to be processed, and then go about their business.

I’ve run across all sorts of really cool queuing technologies, all of which have PHP libraries. So creating and managing job queues was no problem for me. My confusion was how to setup a worker script to process those queues. Read more

Biting the Distributed Development Bullet

Will Code for FoodLike most development n00bs, after I started using version control, I never looked back.  And neither should you.

It required me to change the whole way that my office operated, though.  See, the way that we were doing things before seemed so simple; we just edited files and shouted at each other if we collided in our editing.  As it turns out, this was a bad thing, and there have been better alternatives around way longer than I’ve even been in this business.

But like most crotchety, over-egotistical developer-types it took a while for me to come around.  Here’s a brief history of my flirtations and eventual commitment to version control.

Read more

« Previous Page

Better Tag Cloud