Review: PHP Web 2.0 Mashup Projects // October 22nd, 2007

[Note: Once again, I received a book from Packt Publishing to review for my blog. This time I review a copy of PHP Web 2.0 Mashup Projects. The following is my as honest and objective as possible review.]

In the past couple of years, mashups have become the “new thing” when it comes to web development. Not as over-hyped as AJAX and actually useful, mashups take data from multiple sources (usually web sites through their application programming interface–API) and output the merged data into a single distinct application. Not well experienced with accessing API’s and web services, I decided to create my own mashups involving services I currently use as part of moving my web space from just blog to more of a personal/professional site. Having the desire to work with mashups is a big reason I decided to review PHP Web 2.0 Mashup Projects from Packt Publishing for my blog.

Diving right in this book is aimed at knowledgeable PHP developers familiar with HTML and CSS basics. I would say that the reader should have intermediate PHP skills to be able to understand and follow the example code and application flow of accessing API data.

What I like about this book is that it takes the time needed to explain the various formats, protocols, and web services for accessing data via API’s. As a way to help convey the power, flexibility, and ease of creating mashups, the author provides 5 different mashup project examples. Those projects are: using the Internet UPC database API to find products on Amazon. The second is to create your own search engine with Yahoo and Microsoft Live Search API’s. Third, create your own video jukebox, mashing up YouTube and Last.fm data. The fourth project involves receiving traffic incident updates via SMS. The final project deals with using API’s from Flickr and Google Maps to show photographs based on map location. Each example is thorough, from the overview to instruction on using various methods and protocols to actual coding. I was not very familiar with most of these methods but with the help of the examples I was able gain a better understanding of the technologies and have now even experimented in creating my own mashups with Twitter and Flickr.

I can’t imagine that there is any doubt about the importance of mashups in the future of the web. The idea behind mashups, API’s, and opening up of data is not a trend but a positive shift in thinking of dealing with data. To be viable, web companies now need to offer API, not because it is cool, but because the competition will. This book mentions two companies, MapQuest and Barnes & Noble, that did not and are nearly no longer relevant. And like companies needing to provide access to data and services, developers need to be experienced in dealing with services as well to remain viable. For web developers, in particular front-end developers with below expert level PHP skills (like myself), this book can be a great resource to learning about API’s and web services.

1 Comment

Review: CodeIgniter for Rapid PHP Application Development // September 23rd, 2007

[Note: I recently had the pleasure of receiving a sample copy of CodeIgniter for Rapid PHP Application Development from Packt Publishing to review for my blog. The following is my as honest and objective as possible review.]

Several months ago I mentioned that I had found a new open-source PHP web application framework, CodeIgniter (CI). I used CI to build a light-weight CMS for the administration of a jewelry web site I created for a client. By using CI I was able to complete the construction in a few days rather than weeks. Since that time I have used CI for a variety of personal projects I constructed to gain a better understanding of CI, PHP, application design, and web services.

Had I known about any books providing more details about CI, I most certainly would have purchased one. But I was unaware of any and thus needed to learn as much as I could about CI on my own. So I was glad to receive what is probably one of the first books to cover Code Igniter, CodeIgniter for Rapid PHP Application Development from Packt Publishing which provides plenty of information to get one started in developing CI applications.

To be honest, I had, to my recollection, never heard of Packt Publishing before so I was slightly concerned about the exact level of CodeIgniter expertise presented in this book. But those concerns subsided when I noticed that CI creator Rick Ellis was one of the book’s reviewers, along with Derek Allard and employee of Rick Ellis’ company Ellis Lab. I doubt either would let bad code or bad coding practices to reach publication.

One thing I liked about this book from the start was the author’s writing and the text readability. I have read quite a few technical books in the past few years and many authors go overboard with technical jargon or fake a vocabulary straight from a thesaurus in attempts to either up word count or merely for inflation of ego. David Upton does neither, leaving the book to stand on its own and be a relatively thin at 244 total pages. The text reads more like Upton is teaching you on a person-to-person bassis rather than other books that seem to instruct like a lecture or textbook.

One the back cover of the book, it is accurately stated:

this book explains how to work with CodeIgniter in a clear logical way. It is not a detailed guide to the syntax of CodeIgniter, but makes an ideal complement to existing online CodeIgniter user guide, helping you grasp the bigger picture and bringing together many ideas to get your application development started as smoothly as possible

This book won’t teach you the granular details of CI or how to build the next great app with a few key-strokes. And this book does present a lot of information that is available in the free CI user guide. You may ask, “Then why bother with this book?” Because this book builds upon that information not only to showcase the power of CI, but also provide a better understanding of how to build better applications with CI. Another reason to check out this book is that Upton also provides examples with the afore mentioned readability that allow for a quicker grasp of concepts than the user guide. And in a couple instances Upton also takes time to compare typical PHP code with its CI counterpart. If you’re not swayed by the simplicity of connecting to and querying your database in a few lines of code within CI, I don’t think anything will get you to move to CodeIgniter or MVC coding.

Even though I have been using CodeIgniter for several months now, this book still presented some useful information and provided a better understanding of the CI framework. Some of the things I picked up from reading this book were testing code (unit tests and benchmarking) and a better grasp on the language class. But it’s not all a love fest with Upton and CI, he does keep it objective and reminds you that CI is not perfect, and lets you know what aspects of CI he does have issues with (one of which is one I too have an issue with — the validation class).

As I said before, you won’t get the finer details of CI. But if you’re at that point with CI already, then this book isn’t for you anyway. Again, right on the back cover it is accurately stated, “This book is for developers who are new to CodeIgniter. Basic skills in PHP and MySQL are required, but only rudimentary object-oriented knowledge is required.” If that is you, then you should consider this book to speed up the learning process with CI.

The book does seem to be a bit steep in price at $35 US for 244 pages, especially if you consider the user guide and forums. However, what I learned about CodeIgniter these past few months occurred after wading through literally hundreds of useless forum and blog posts and spending hours going through my own trial and error of coding to figure things out. Right now, I have a hard time deciding whether or not I would pay $35 for this book since I am already familiar with CodeIgniter, but if I had to go back to when I first started learning about CI, then it would be a no-brainer to buy.

No Comments

Where have you been, CodeIgniter? // March 9th, 2007

For the past several months I have have been trying to use several different web application frameworks. None of them were a right fit for me for several reasons, either they lacked in documentation, were slow, required other software libraries, or were built in other languages that would take took long to learn.

For example, I tried Ruby on Rails for a majority of the time. I had the books, checked the blogs, installed it on my development server, but it just didn’t work out. The lack of sufficient documentation is the primary reason I jumped from the Ruby on Rails bandwagon. I also didn’t appreciate the “don’t worry about the magic behind Rails” because I need to know how things work to debug errors. And sure enough when errors came, I spent most of my free time searching for the answers. It doesn’t live up the hype, like most fads.

I decided it would be best to stick with PHP, a language I’ve used since 1999 and take a closer look at the PHP frameworks. This crop wasn’t much better than Rails, each one of them lacked in one or more areas; immature code and or configuration, lacking in documentation, or requiring annoying PEAR libraries. All this caused me to lose interests in these, if not all, frameworks.

It was time to put up or shut up and I went to the drawing board with plans on creating my own framework for my own projects. Less than 24 hours later, as luck would have it, I came across Code Igniter, a fast open source PHP web application framework with more than enough documentation and no need for any PEAR libraries. Installation is quick and simple with the configuration requiring more time, about 3 minutes.

I had been using CodeIgniter for several days, creating simple scripts to get a hang of the system. Then on Sunday night I decided to jump right in a create my first project, a fully functional administration web site for my sister’s jewelry business. Here it is late Thursday night and I am about 80% complete, and that is with me traveling to southern California Monday morning and returning Wednesday evening.

CodeIgniter is the framework I have been looking for since this time last year. It is fast, simple to use, elegant, well documented, stands on its own, open source, and powerful. Now all the projects I had to clear off the table because developing other ones would take too long are back on.

2 Comments

  • The Netflix Prize is a 1 million dollar reward given to whoever can create a Netflix rating system that "is 10% better than what Cinematch can do." I've already registered and downloaded the data because I need another project I'll never complete. (0 Comments)
  • Yea! I finally made it into Amazon's EC2 beta. EC2 allows users to "...use web service interfaces to requisition machines for use, load them with your custom application environment, manage your network's access permissions, and run your image using as many or few systems as you desire". I don't know what I'll do with this exactly, but I think it will be interesting/fun to figure it out. (1 Comment)

AJAX & Images // September 19th, 2006

I would like to create a small web application for a couple of projects that utilizes AJAX in getting a “next” or “previous” image, but because I have never truly developed anything of significance with JavaScript I don’t know where to begin.

The desired outcome would be a little similar to the Flickr photostream viewer. flickr viewer But with this, I need the advancing or retracting images to go over a background image and have the “scrolling” images appear over the background until they reach the end of the image and then disappear/fade out. I have looked at script.aculo.us and other effects libraries but I am not having any luck finding something that could get me started. I could use some examples or the Flickr script to try to hack something together, but then what would be the point of learning something new? So, if anyone could point me in the right direction with tutorials or examples, I would appreciate it.

1 Comment