Wicked Cool PHP – Review
I’ve been reading tons of books lately, mostly to do research into technologies I’m thinking about trying out. I have several projects going on and I’m primarily a java developer. For a new project I just started last week I’ve decided to give it a go using PHP, which I’ve never touched before. My main reason for this was, from what I hear, that PHP is good for simple projects that need a fast turn around. This is exactly what I’m looking for, in addition to integrating with wordpress. I starting going through a bunch of lame tutorials on the web, but they’re mostly geared for a beginner and there’s a lot I can skip over. I decided to get a couple of recommended books on PHP and one that I found very useful is called Wicked Cool PHP: Real-World Scripts That Solve Difficult Problemsby William Steinmetz with Brian Ward.
Why this book is useful
Sure I need to see basics on the PHP syntax, but nothing in depth and not a million pages covering if/then, looping, etc. What I need to know is:
- how can I quickly parse some XML
- how can I read and parse a file from a web URL
- basics on session handling
- how to select some mySQL database rows
- a rundown on security and making a PHP app more secure
This book covered all of this with nice clean short examples. One of the things that I also like about this book is the layout. It’s kind of setup like a cookbook, so you don’t have to read straight through front to back (although I did). If you want to read up on manipulating images and CAPTCHA you can flip to that section and you won’t feel confused because you skipped several chapters. Hands down the best chapter in the book is Chapter 3 PHP Security. This chapter discusses hashing, SQL injection , and XSS attacks , but this chapter also has the most important section in the book title “Recommended Security Configuration Options“. This, less than a page, section was a bulleted list of what you need to change in your php.ini to get your PHP installation ready to run on a production server. This was gold.
Who should read this book
If you’re new to programming then this probably isn’t the book for you. In fact, if you’re new to PHP it may not be the book for you. This book is for intermediate PHP developers that want to get things done fast. All in all I give the book a 5 out of 5 because not only is it a good learning tool but becomes a great reference book. If I had to pick a weak point it would be the last chapter which gave several large examples to pull the book’s code together, which might be what others like but wasn’t what I needed.
Lastly, if anyone can recommend some good books on frameworks (MVC or other) for PHP to use with larger projects, please leave a comment with the book name.