Buy this Book
Print Book $29.99 PDF $20.99 Read it Now! Print Book £18.50
Add to UK Cart
Reprint Licensing
Learning PHP & MySQL, Second Edition Step-by-Step Guide to Creating Database-Driven Web Sites

By Michele E. Davis, Jon A. Phillips
Second Edition  August 2007 
Pages: 428
ISBN 10: 0-596-51401-8 | ISBN 13: 9780596514013
starstarstarstarstar (Average of 3 Customer Reviews)

Buy 2 Get 1 Free Free ShippingGuarantee

Book description

PHP and MySQL are quickly becoming the de facto standard for rapid development of dynamic, database-driven web sites. With concepts explained in plain English, the new edition starts with the basics of the PHP language, and explains how to work with MySQL, the popular open source database. You then learn how to put the two together to generate dynamic content.
Full Description

PHP and MySQL are quickly becoming the de facto standard for rapid development of dynamic, database-driven web sites. This book is perfect for newcomers to programming as well as hobbyists who are intimidated by harder-to-follow books. With concepts explained in plain English, the new edition starts with the basics of the PHP language, and explains how to work with MySQL, the popular open source database. You then learn how to put the two together to generate dynamic content.

If you come from a web design or graphics design background and know your way around HTML, Learning PHP & MySQL is the book you've been looking for. The content includes:
  • PHP basics such as strings and arrays, and pattern matching
  • A detailed discussion of the variances in different PHP versions
  • MySQL data fundamentals like tables and statements
  • Information on SQL data access for language
  • A new chapter on XHTML
  • Error handling, security, HTTP authentication, and more
Learning PHP & MySQL explains everything from fundamental concepts to the nuts and bolts of performing specific tasks. As part of O'Reilly's bestselling Learning series, the book is an easy-to-use resource designed specifically for beginners. It's a launching pad for future learning, providing you with a solid foundation for more advanced development.

Browse within this book

Cover | Table of Contents



Featured customer reviews

Write a Review


Second Edition? Huh?,  March 26 2008
Rating: StarStarStarStarStar
Submitted by Tommy Dugandzic   [Respond | View]

I was shocked at the overall low quality of this book considering O'Reillys Perl books were so good. Let me give examples:

On page 249 the author gives an example of how to make the system call "df" in linux and then print the results on a html page. In the 9 lines short example he makes two errors. First he starts the <pre> tag with "</pre>" instead of "<pre>". Ok, that can be obvious for some readers and they can quicly correct it. But then he writes this in the same example:

exec(escapeshellcmd(“df”),$output_lines,$return_value);
echo “$o”;
}

WTF? Considering the very point of his example is to show how to output the contents of a file, his error is not obvious. In one place he calls the variable $output_lines and in the other place he calls it $o. That is not simply a typo.

On page 51 he calls the character "\" backslash, which is correct. On page 52 he suddenly starts calling the character "slash" instead of "backslash". He does that consistently three times on the same page.

If this would have been a story book I would have kept reading anyway if the story would have been good. But these kinds of errors are unacceptable in a book that teaches programming where every letter is crucially important. I make enough errors on my own learning a new programming language. I don't want to guess what errors are mine and what come from the author of the book.

The illustrations that are supposed to help you understand basic concepts such as variables only confuse you. It feels like the author added them afterwards because his boss forced him too, and not because the author really wanted to include any himself.

I read the first 70 pages (I skipped the sections describing how to install PHP and its prerequisites since I already knew how to do that) and I didn't catch even one joke nor pun during that time. I remember the O'reilly Perl books where full of them. Ok, I'll admit humor is not essential to a programming book but it really makes the read so much more enjoyable with clever little puns.

I do not recommend this particular book to anyone. The O'Reilly Perl books and HTML books on the other hand were very, very good. So if you have a few books to choose from I would recommend the O'Reilly one. In general, that is.



Second Edition? Huh?,  January 31 2008
Rating: StarStarStarStarStar
Submitted by Derek   [Respond | View]

When I received notification from O'Reilly that they were going to replace my copy of Learning PHP & MySQL for free based on the negative feedback received about the first edition, I was pretty excited. I hadn't yet delved into my first edition copy, and so I figured I'd get a nice refresher on PHP and MySQL by waiting to dive into the second edition. Imagine my surprise to find that the second edition is rife with typographical errors, inconsistencies in code examples, and bits of code in entirely wrong places! The command-line MySQL tutorial swaps table and field names between examples, making them awkward to work with, and typos in the code examples ("< strong > ... </ string >") could easily confuse novice web designers. I was finally prompted to write this review when reading the section on "Validating text boxes and text areas" that completely inappropriately reused the code example from the previous section, "Validating checkboxes, radio buttons, and selects".

I generally love O'Reilly books and recommend them readily to people looking for reference guides or tutorials, but I'll definitely be pointing people to other titles (albeit probably other O'Reilly titles) rather than this one for an introduction to PHP and MySQL.


Not bad at all,  October 16 2007
Rating: StarStarStarStarStar
Submitted by Leam   [Respond | View]

I really enjoyed reading this one! The authors have an easy style that lets you accelerate if you already have a good grasp of that topic but want a refresher. If the section covers something you don't know then there are clear code examples and text that explains what the code does.

Don't make the assumption you'll learn lots of PHP and MySQL from one book! You'll get an introduction to both that is much lighter than covered in other O'Reilly books. Where this book shines is in the juncture of the two; it really makes clear some of the ways you can customize web pages using a database. Once you lay this one down you should spend a few hours with a favorite beverage; just toss some of the possibilities around in your head.

If you have a beginning understanding of PHP and/or MySQL, this book will help you take the next step. It will also help you understand technologies like Joomla and other database-driven websites. You won't learn how to program, in a general sense, but you'll get turned on by the possibilities. If you're already a coder but new to PHP and MySQL, you'll get a taste of what can be accomplished with this powerful combination.

Read all reviews


Media reviews

"After you’ve mastered the fundamentals, you might want to continue your SQL study with another fine O’Reilly book, Learning PHP & MySQL (2nd Edition). The book, intended for beginners — beginners with some HTML and graphic design background — covers more topics and goes into greater depth than its Head First cousin. Despite the cute kookaburra birds on the front cover, the tone of this SQL book is less casual, but the writing style is equally clear."
-- Epublishers Weekly, Tools and Ideas for Surviving (and Thriving) in Technopoly

"For the techies interested in using open source technologies in the above domain, this book gives a useful introduction to working on the M and P out of the LAMP architecture. The concepts introduced in this book are useful for developing MySQL database linked dynamic websites based on PHP ."
-- Ganadeva Bandyopadhyay, Desicritics.org

"The discussions on Cookies, Sessions and Access Control, Security and Validation , and Error Handling make this a well-rounded book for the basic to the intermediate readers and implementers of these technologies. One particular aspect that seems to be a possible good addition to future editions of this book is the interaction with application servers in between the web and the database when considering these open source technologies."
-- Ganadeva Bandyopadhyay, Desicritics.org

Read all reviews


See larger cover


"After you’ve mastered the fundamentals, you might want to continue your SQL study with another fine O’Reilly book, Learning PHP & MySQL (2nd Edition)."
--Epublishers Weekly, Tools and Ideas for Surviving (and Thriving) in Technopoly