Please create an account to participate in the Slashdot moderation system

 



Forgot your password?
typodupeerror
×
Books PHP Book Reviews

CodeIgniter 1.7 Professional Development 75

RickJWagner writes "CodeIgniter is a multi-purpose, open source PHP web application framework that can dramatically reduce the amount of coding required in developing a full-featured website. This book promises to introduce the reader to the most productive APIs and demonstrate their usage with minimal code snippets. In that regard, I think the book lives up to its promise." Read on for the rest of RickJWagner's review.
CodeIgniter 1.7 professional development
author Adam Griffith
pages 300
publisher Packt Publishing
rating 9/10
reviewer RickJWagner
ISBN 1849510903
summary For advanced PHP developers who wish to use CodeIgniter to make their development easier, quicker, and more fun.
The first chapter covers CodeIgniter's MVC framework, which provides a way for a programmer to logically partition code so it's easier to maintain. For those of us who aren't accomplished PHP coders, this chapter also contains a PHP style guide, which I thought was a nice feature. By the way, the code snippets throughout the book are clean and easy to read -- the author must have followed his own advice on code style.

The second chapter is an introduction to some of the more productive libraries you'll find in CodeIgniter. Here you'll find some excellent advice on how to take timing metrics in your application, how to secure it, and how to accomplish routine activities like retrieving data from the user's request. Other 'web topics' are addressed here, like how to manipulate the session, how to manage emails and file uploads, and much more.

Chapter 3 handles form inputs and databases. As is common throughout the book, the reader is given minimal technical overview. What you'll find instead is a very brief explanation of what's about to be covered, then a few very readable source lines that demonstrate use of CodeIgniter in action. If this book were your only resource, I'm sure there would be times where you didn't find enough material to get everything done you wanted to do. But if you have a web browser (and Google) handy, a book of this type can be an effective index to help you find the parts of a framework you want to leverage.

The next few chapters cover user authentication and application security. I found these to be a little spotty -- heavy in some places, light in others. Still, the material was useful and not difficult to read or understand.

A nice chapter on tips for building a large-scale application was next. I found this one interesting -- many of the ideas were well-known, but a few had not occurred to me before. I liked reading it. Next up was a chapter on Web Services. I didn't take the time to test the provided code for this chapter, but I would like to sometime. If it works as I hope it will, I may have a new way to stand-up test web services!

The final two chapters are on extending CodeIgniter (it's great that the library authors institutionalized this!) and donating code back to the community.

So who is this book for? The book itself tells you it's for expert PHP coders, but I don't believe that's exactly right. Given the easy-to-read nature of the book and the light treatment given to some of the meatier topics, I'd say this book is about right for a novice-to-intermediate-level PHP coder. I haven't done a lot in PHP, yet I found the code reading very easy.

If I had a wish for the book, I'd wish for a little more depth in the harder topics and maybe some quick overviews for a few topics. (Diagrams accompanying the overviews would be nice, too. This book has few illustrations except for screenshots.)

All things considered, I'd recommend this book to coders who are getting started with PHP and CodeIgniter. It's easy to read and will get the reader pointed in the right direction for solving many web problems.

You can purchase CodeIgniter 1.7 professional development from amazon.com. Slashdot welcomes readers' book reviews -- to see your own review here, read the book review guidelines, then visit the submission page.

*

This discussion has been archived. No new comments can be posted.

CodeIgniter 1.7 Professional Development

Comments Filter:
  • How crappy can they all be that a new one pops up every other week?
    • Re: (Score:2, Informative)

      by sockman ( 133264 )

      CodeIgniter has been around for a while, dude.

    • Re:PHP frameworks (Score:5, Informative)

      by Anonymous Coward on Wednesday June 09, 2010 @01:01PM (#32513650)

      umm, CodeIgniter is about 4 years old now. Perhaps they don't pop up every other week, you've just never heard of most of them since you're probably not a PHP developer.

    • Nah, not every other week, but every year it's a different framework that is the "Coolest thing ever and everyone who isn't using it is dumb" according to most of the PHP developers I know and work around. CI was their popular choice in 2007/2008. That was going to rock the web development world after the whole Ruby on Rails thing died down. 2008/2009 all I heard about was Drupal being the coolest framework ever. Before CI it was CakePHP. That was 2006/7ish. Before Cake, Zend was all the rage.

      I was the

  • Snails? (Score:5, Funny)

    by PatPending ( 953482 ) on Wednesday June 09, 2010 @12:59PM (#32513620)

    The cover photo is of... snails?

    Naturally, the immediate association is with "a snail's pace."

    +1 for unintended consequence. Sigh.

  • open source PHP web application framework that can dramatically reduce the amount of coding required in developing a full-featured website

    and dramatically increase the amount of unnecessarily executing code.

    if your project doesn't function, how could you not have seen that without mocking it up? and if it does work, now you have to recode it completely to make it scalable. i never understand the lure of these development platforms on top of development platforms.

    • by lwsimon ( 724555 )
      CI is probably the best at not adding layers and layers of cruft of all the frameworks I've tried - with the possible exception of Django.

      Then again, i can think of several high-traffic sites using Django, but not of a single one using a PHP framework...
      • the layers and layers are unnecessary steps in the procedural logic pathways that result in increased latency and overall memory footprint... generally the very first things addressed when optimizing a system.
        • by lwsimon ( 724555 )

          I'm aware - I'm not saying that using a framework is great idea for a highly scalable system, only that CI is probably the *least bad* of all the PHP frameworks.

          And honestly, if you're that concerned about scalability, you're not going to be using PHP.

          • by AvitarX ( 172628 )

            And honestly, if you're that concerned about scalability, you're not going to be using PHP.

            I know that it isn't always the smoothest, but Facebook is PHP, and is pretty fricken huge.

            • by lwsimon ( 724555 )
              Facebook has grown organically from a very small site. If you had to write Facebook, knowing that it would grow to the size it is today, would you use PHP?
            • by gauauu ( 649169 )

              I know that it isn't always the smoothest, but Facebook is PHP, and is pretty fricken huge.

              Sort of. According to what an employee told me last week, lots of the core services are written in other languages, and then PHP is the glue that queries those services and builds the page itself. They then have found that that really isn't fast enough for what they want, so they've written their own compiler (Hip Hop [github.com]), which compiles PHP down to C++ which can then be compiled by G++.

              So yeah, facebook uses it. But

            • by soppsa ( 1797376 )
              As a result of using PHP, they have an awful server/visitor ratio, far worse than what most large scale webapps accomplish using alternate languages. And on top of this, their 'PHP' isn't really what most people consider PHP, compiled to C++, etc.
          • I agree. Rasmus even says "Any script based language is simply not fast enough". And frameworks are going to slow you down as well. But, when you compare how many real high traffic sites there are on the internet to how many low to medium traffic sites there are, you can clearly see that there is a place for PHP frameworks. Maybe not at the most elite levels, but definitely a big place. I think of PHP as the Toyota of web application languages (especially apt in light of Toyota's recent history)
            • maybe if Toyota's were offered with mr. fusion options to turn garbage into fuel...

              PHP with the zend optimizer or any other compile/cache bytecode tools, has performance not worse than 10% of "pure" compiled servers doing the same tasks.

            • by lwsimon ( 724555 )
              I would also argue that once an application gets big enough that it needs that level of optimization, it probably needs to be rewritten anyhow, and you can afford to hire the best of the best to do it.
      • i've heard of several sites that use Drupal, but don't frequent any of them.... i know many many sites run on custom frameworks in PHP and Python or similar. nowadays, there is generally a rpc service layer with minimized custom clients/servers, but i've seen many of those running PHP on lighttpd and getting similar throughput results to purely custom rpc servers written in python or C.
      • In my experience, the only decent PHP framework is Wordpress. Seriously, you can do a hell of a lot with very little work just by creating a theme and using three or four plugins. You can crank out an awesome, somewhat customized (feature-wise, I mean), client-editable site in a day, counting the graphics work, and 99% of the maintenance is just updating Wordpress when a bugfix or new version comes out. It's hard to beat that for smaller sites.

        I've found that if I can't do it without any framework or wit

  • It doesn't strike me that somebody who can understand the CodeIgniter user guide would benefit at all from this book and I'm assuming that's what the target is given it has "Professional Development" in the title. The CodeIgniter user guide is some of the best documentation I've seen for any framework in any language.
  • I am sorry, but the framework still supports PHP version 4.3.2. Support for PHP 4 was ended at the end of 2007. Any framework that doesn't take advantage of the nice new features in PHP 5 bound to be full of kludges and outdated code.

    That is just my reaction based on when I was comparing PHP frameworks, I didn't dig into their code so maybe I am wrong.

    • I am sorry, but the framework still supports PHP version 4.3.2. Support for PHP 4 was ended at the end of 2007. Any framework that doesn't take advantage of the nice new features in PHP 5 bound to be full of kludges and outdated code.

      That is just my reaction based on when I was comparing PHP frameworks, I didn't dig into their code so maybe I am wrong.

      I haven't dug in too far, since I'm paid to spend my time working on my company's proprietary framework, but CodeIgniters seems to have done a pretty good job in how they've gone about maintaining PHP4 support. Clever solutions rather than outdated ones, to put it briefly. It also seems pretty easy to just use the parts of their code you need, and of course any code you write either within the framework or as a plugin can be 100% PHP5.

    • by salmonmoose ( 1147735 ) on Wednesday June 09, 2010 @02:08PM (#32514652) Homepage
      It supports PHP 4, but doesn't rely on it - they have separate code-paths for PHP4 and 5, and some features just don't work in 4.
    • by lwsimon ( 724555 )

      I believe CI 2.0 will break compatibility with the PHP 4 tree. Why is waiting until the next major revision to break compatibility a bad thing?

      PHP 5 adoption is taking a long time, too. There are still webhosts that only offer 4.3.x. They suck, but they're out there.

  • by uprise78 ( 1256084 ) on Wednesday June 09, 2010 @01:44PM (#32514322)
    Highly recommended for anyone out there looking for a PHP framework that actually makes sense.
    • by Leafheart ( 1120885 ) on Wednesday June 09, 2010 @02:13PM (#32514720)

      Highly recommended for anyone out there looking for a PHP framework that actually makes sense.

      Wish I had mod points. Kohana is the natural evolution of CI and made for PHP 5. It is much, much better than CI.

      • by lwsimon ( 724555 )

        Kohana's documentation is giving me a server error. CI's major features is it's documentation. No thanks :)

        • Re: (Score:3, Interesting)

          by Shaiku ( 1045292 )
          I guess you didn't bother to read the message with links to both the old and new documentation, or the note that points out that the documentation is in the userguide module of all releases. If it looks like an error message, it must be an error message, right?

          And your logic is flawless. We should totally disregard any product or entity with a website that ever goes down for any reason. I've got a lot of documentation for TI Extended BASIC. Maybe you'd like to switch over? To hell with the merits of
          • TI Extended Basic - you just flipped me into serious nostalgia mode.

            • by Shaiku ( 1045292 )
              I've got about 3 99/4a's and a peripheral expansion box. Wish I still had my Corcomp 9900 :( Getting more nostalgic?

              OLD CS1
              RUN

              oh yeah
        • Re: (Score:2, Informative)

          by lagi ( 303346 )

          get last kohana from github, install the userguide, read docs.
          you'll thank me later.

      • by lagi ( 303346 )

        you're right 100%, using Kohana for few months now, won't replace it for anything (using CakePHP for almost 2 years)
        and if we talk about shame, PHPStorm PHP IDE puts every other PHP IDE to shame.

    • Re: (Score:2, Interesting)

      by Shaiku ( 1045292 )
      Yeah if you're looking for a PHP framework, skip over CI and start off with Kohana. Kohana is much better and makes a lot more sense for new development. Really more people need to hear about Kohana and not CI.
  • This review is nothing but spam. Go look at the Amazon reviews. The author is allegedly a 17 year old student, which I'll leave at that.
    • by malakay ( 900604 )
      The age of an author does not necessarily matter when analyzing the quality of the content. You are stereotyping by age, and therefore your argument should be discarded.
  • What are the fundamentals of a "Simple MVC Model for PHP?" Then what makes these fundamentals for a "Simple MVC Model for PHP", fundamental?

Every nonzero finite dimensional inner product space has an orthonormal basis. It makes sense, when you don't think about it.

Working...