Worst Book I Have Ever Used
This book is full of errors and unexplained concepts. It is the worst book I have ever read. I can't believe the author or editor ever checked to see if there were any errors, and that everything made sense. This is horrible for O'Reilly's reputation. I probably will not buy another O'Reilly book.
In a word, "Terrible."
This book is terribly written. There are typos everywhere, both simple grammar typos and coding/logic typos. For a beginner to the material it is extremely nerve wracking to follow. Not only do the typos throw you for a loop, but it has no logical flow to the material. For example, they go over creating tables in Chapter 7, but you they don't tell you how to use mysql until chapter 8. Then in the middle of chapter 8 (p 137) they tell you to create an NEW database, followed immediately by a section on how to manipulate a table (in this example, `books`) in that new database (p 138). Problem is, ERROR: there are no tables! You just created a new database and it is empty! The table they are referring to was used as an example to explain database concepts in Ch 7 (p 124).
I love(d) my O'Reilly books but I will NEVER buy another one blindly again. Even worse, I read review for the second edition and apparently not much if any of these major problems have been fixed.
I find it extremely hard to believe that anyone who gave this book a decent rating actually used this book to learn PHP & mySQL or even read it through.
A waste of $30 -- ALL NEWBS SHOULD AVOID!
I came to this book as a newbie, with some knowledge of HTML and CSS, and that's about it. This book nearly killed my desire to learn PHP/MySQL.
The problems start early, in Chapter 2. The installation information is seriously flawed. Many of the links they point you to are dead. And even when I went to the book's web site for an updated link, and followed the instructions to the letter, I still wasn't in business. I googled to try to get help and stumbled across some other lost soul using this book, with exactly the same problem as me. Guess what? He was begging for help on a message board somewhere. I should have realized right then that this book was worthless. But I soldiered on.
I managed to get PHP and MySQL downloaded (though the connector was still not working), and started working on some of the PHP coding. I learned some PHP, sure, but it was a slow, slow process. Practical applications? Practice exercises? Clear explanations for inexperienced computer programmers - presumably the kind of people who would be buying a book like this? Rare or nonexistent.
I skipped ahead to the MySQL section, made it in a few pages, and then they recommended that I install PhpMyAdmin. Well, I did, and then I ran into the problem with the lack of connection between PHP and MySQL again. So I went back to Chapter 2, and wasted another hour of my life trying to figure out how to get the past the basic installation issues.
So, yeah, I paid $30 so I could figure it all out for myself. And I still haven't. So thanks a lot, folks. You took $30 of my hard-earned money, and in return gave me several hours of aggravation.
I know the computer experts out there will laugh at this review - they always think they're superior to newbs. But I know I'm not stupid. A better book will teach me the basics of PHP and MySQL, I just need to find it. This one is not newb-friendly. And if a how-to book isn't newb-friendly, then as far as I'm concerned it ain't worth a thing.
NEWBS BEWARE. YOU'VE BEEN WARNED.
A good read, but not without its flaws
I enjoyed this book. I felt like it did a good job introducing both PHP and MySQL without being overwhelming. However, I wasn't so impressed with how it covered Object Oriented PHP, or how it introduced PEAR and Smarty.
For the most part, the OOP section seemed to be put in there as an after-thought. Also, the book switched gears pretty quickly between using the standard PHP libraries for getting things done, to using PEAR. And, there really wasn't much of an explanation accompanying the inner-workings of Smarty - more of a "here's the code, it does this" kind of an approach. What makes this so frustrating is that you learn a bunch of stuff earlier in the book that you don't see being used in the later examples (or the big final example in Chapter 17, which I'll address next).
The biggest let down I found was that if you followed the final example (Chapter 17 - building your own web app), it doesn't even work. At first, I wrote it out myself from the code in the book, so I could follow along closely and try understand what was going on. It didn't work, so I assumed my code was filled with typos. I registered on-line with O'Reilly and was able to access the book on their website. From there, I copied and pasted the scripts for the web app directly into the various .php and .tpl files on my machine, and made sure to name them exactly as they are named in the book. It still didn't work!
There are inconsistencies in how scripts are named and referenced in other scripts. And the best part is that it doesn't even include the script for logging out and ending your session, even though there is a link to it (logout.php) in the footer.tpl Smarty template file. I know it isn't that difficult to make your logout script based on some of the scripts from the earlier chapters, but it's still the fact that they leave out a whole part in the final example. Ultimately, I can't help but wonder how difficult it would have been for the authors to verify that the website did what it was meant to do, before putting it in their book.
I know it sounds like I am giving this book a harsh review... However, I did truly enjoy it and that is why it is still getting 4/5 stars. The negative points I brought up were not enough to bring down the overall effectiveness of this book as a learner's guide to PHP and MySQL, but definitely merits mentioning as a warning to potential readers/buyers.
Learning PHP and MySQL
PHP and MySQL are highly adaptive programs that can be used to create a variety of dynamic website potentials. Although fairly simple to use once you understand the basics, the learning curve on these programs is a little high at first. In order to use the capabilities, the user has to not only understand what the programs do and how they work together. However, probably the hardest part of the process is learning all the vocabulary associated with these systems.
Learning PHP & MySQL is a very good reference, especially for this latter challenge. The guide not only defines and explains each of the different concepts but gives examples that better illustrate these aspects while giving the user a glimpse into how they could use them for their own purposes. Especially for the more difficult sections, I really liked that I could replicate the code on my computer and see the results for myself. This aspect gave me a far better idea of how I could use these programs in conjunction to create the effects I want.