Volume 2 covers the applications of PHP in the real world including authentication & access control, XML, stats & tracking, caching data to improve performance, design techniques and design patterns. The chapter on Design Patterns is particularly unique as it teaches readers about common object architectures which can be used to solve common (though unique) problems.
In addition to being an excellent reference with over 60 customizable solutions, the book acts as an excellent primer for Object Orientated Programming. PHP 5 has now been released and has been given significant OOP features, which are a must-learn for PHP Developers.
All code in the book is backwards compatible with earlier versions of PHP.
Preface Who should read this book? What s covered in this book? The Book s Website The SitePoint Forums The SitePoint Newsletters Your Feedback Acknowledgements Access Control How do I use HTTP authentication with PHP? How do I authenticate users with sessions? How do I build a user registration system? How do I protect my site from auto sign ups? How do I deal with members who forget their passwords? How do I let users change their passwords? How do I build a permissions system? How do I store sessions in MySQL? How do I track who is online? Further Reading XML SAX, DOM and PHP How do I parse an RSS feed with PHP and SAX? How do I parse an RSS feed with PHP and DOM? How do I generate an RSS document with PHP and DOM? How do I perform XPath queries with PHP? How do I transform XML with PHP? How do I build an XML-RPC service with PHP? How do I consume SOAP Web services with PHP? How do I build a SOAP server with PHP? Further Reading Alternative Content Types How do I render PDF documents with PHP? How do I convert HTML to PDF? How do I render SVG with PHP? How do I render WML with PHP? How do I render XUL with PHP? Further Reading Stats and Tracking What information can I gather about my site s visitors? How do I store visitor statistics with PHP? How do I recognize returning visitors? How do I track exit links? How do I record search engine queries? How do I exclude search engines from my logs? How do I get reports on my site s statistics? Further Reading Caching How do I prevent Web browsers caching a page? How do I capture server side output for caching? How do I implement a simple server side caching system? How do I control client side caching with PHP? Further Reading Development Technique How do I optimize my code? How do I structure my application into layers? How do I read API documentation? How do I generate API documentation? How do I set up automated tests of my code? Further Reading Design Patterns The Factory Method The Iterator Pattern The Strategy Pattern The Adapter Pattern The Observer Pattern Further Reading PHP Configuration Configuration Mechanisms Key Security and Portability Settings Includes and Execution Settings Error-Related Settings Miscellaneous Settings Hosting Provider Checklist General Issues PHP-Related Issues Security Checklist The Top Security Vulnerabilities Working with PEAR Installing PEAR The PEAR Package Manager Installing Packages Manually Index