ASPit - Totally ASP JSit - Totally JavaScript
Search PHPit

Use this textbox to search for articles on PHPit. Seperate keywords with a space.


Book Review: PHP5 Recipes: A Problem-Solution Approach

(Page 2 out of 2)

In chapter ten ("Working with Variables") you are introduced to working with variables in PHP. Seems a bit weird to me that we get this chapter so late in the book, especially after we've had much more complicated chapters (i.e. chapter two), but I digress. This chapter goes over the basics, like assigning values, typecasting, and using constants, but it also shows you how the serialize() and unserialize() functions work and how to share variable data between processes using the shmop_* functions. Not a bad chapter really, although the first part can easily be skipped.

Chapter eleven ("Using Functions") is another chapter that introduces a really basic concept, and again I have to wonder if I haven't started the book at the wrong end. Why is the use of functions discussed after something like objects, classes and interfaces? Nothing earth-shattering is introduced in this chapter and it even misses a few chances to introduce new PHP5 features, such as failing to mention the ability to use exceptions when talking about returning failures from functions.

In chapter twelve ("Understanding Web Basics") the author introduces you to various web tasks, such as setting cookies, using sessions, passing data through querystrings and more. Most of the things in the chapter are quite obvious, and well-known to most developers, but there are a few handy tips and tricks, such as forcing file "Save As" downloads and more.

Related to chapter twelve is chapter thirteen ("Creating and Using Forms") which talks about everything related to forms and form validation. Topics discussed in this chapter include GET vs. POST, the superglobals ($_POST, etc), and more. It also includes a detailed description of handling file uploads, which can be a bit daunting in the beginning.

Chapter fourteen ("Working with Markup") introduces a few more advanced topics, such as the DOMXML extension, working with XML, RSS feeds, WDDX, SOAP and more. Compared to the previous chapter, this chapter is much more interesting, and is even appealing to an experienced developer.

Chapter fifteen ("Using MySQL Databases in PHP 5") is all about using a MySQL database together with PHP. The first part of the chapter demonstrates the use of PHP's regular mysql_*() functions, but the second part of the chapter takes a look at PHP5's new mysqli extension, and explains the differences between the older mysql_* functions and the mysqli extension. It's good to see some PHP5 functionality explained, after several chapters of no new PHP5 information whatsoever.

Finally, chapter sixteen ("Communicating with Internet Services") is a small chapter on doing various internet-related tasks, such as sending e-mail, performing DNS lookups and more. There's nothing really special in this chapter, although it does contain a few interesting code snippets, like for instance code for a domain WHOIS tool.

Final Verdict

I must admit that I'm somewhat disappointed with this book, but that's probably due to my initial expectations. Before having read the book, I was expecting to mainly read about PHP5's new and exciting features, as the title of the book implies.

But instead, this book was mainly about PHP's "old" features, and very little new PHP functionality is discussed. Only chapter two introduced a decent chunk of PHP5 information, but the rest of the book contains hardly any information on PHP5's new features.

This book is probably perfect for the intermediate PHP developer. I wouldn't recommend it for the absolute beginner, but for someone who's got programming experience but no PHP experience, this is the perfect book.

However, if you consider yourself to be quite experienced, I don't recommend this book, as the biggest part of the book will be reveal nothing new, and can be skipped.

I'd like to thank the publisher, Apress, for sending me a free copy for reviewing purposes.

« Previous: Introduction & Part One

2 Responses to “Book Review: PHP5 Recipes: A Problem-Solution Approach”

  1. Says: Book Review: PHP5 Recipes: A Problem-Solution Approach…

  2. Ghica van Emde Boas Says:

    If you really want to read an excellent book, just about the new features of PHP 5, read “Upgrading to PHP 5″ by Adam Trachtenberg (O’Reilly).

Leave a Reply

About the author
Dennis Pallett is the main contributor to PHPit. He owns several websites, including ASPit and Chill2Music. He is currently still studying.
Article Index
  1. Introduction & Part One
  2. Part Two & Final Verdict
Bookmark Article
Download Article
Download this article as a PDF file