Modern PHP
O'Reilly Media (Verlag)
978-1-4919-0501-2 (ISBN)
PHP is experiencing a renaissance, though it may be difficult to tell with all of the outdated PHP tutorials online. With this practical guide, you’ll learn how PHP has become a full-featured, mature language with object-orientation, namespaces, and a growing collection of reusable component libraries.
Author Josh Lockhart—creator of PHP The Right Way, a popular initiative to encourage PHP best practices—reveals these new language features in action. You’ll learn best practices for application architecture and planning, databases, security, testing, debugging, and deployment. If you have a basic understanding of PHP and want to bolster your skills, this is your book.
- Learn modern PHP features, such as namespaces, traits, generators, and closures
- Discover how to find, use, and create PHP components
- Follow best practices for application security, working with databases, errors and exceptions, and more
- Learn tools and techniques for deploying, tuning, testing, and profiling your PHP applications
- Explore Facebook’s HVVM and Hack language implementations—and how they affect modern PHP
- Build a local development environment that closely matches your production server
Josh Lockhart is the creator of the Slim Framework for PHP. He also created and maintains PHP The Right Way, a popular initiative in the PHP community to encourage best practices and provide quality information. Josh is a senior developer at New Media Campaigns, a full service web design, development, and marketing agency in Carrboro, North Carolina.
Language Features
Chapter 1The New PHP
Past
Present
Future
Chapter 2Features
Namespaces
Code to an Interface
Traits
Generators
Closures
Zend OPcache
Built-in HTTP server
What’s Next
Good Practices
Chapter 3Standards
PHP-FIG to the Rescue
Framework Interoperability
What Is a PSR?
PSR-1: Basic Code Style
PSR-2: Strict Code Style
PSR-3: Logger Interface
PSR-4: Autoloaders
Chapter 4Components
Why Use Components?
What Are Components?
Components Versus Frameworks
Find Components
Use PHP Components
Create PHP Components
Chapter 5Good Practices
Sanitize, Validate, and Escape
Passwords
Dates, Times, and Time Zones
Databases
Multibyte Strings
Streams
Errors and Exceptions
Deployment, Testing, and Tuning
Chapter 6Hosting
Shared Server
Virtual Private Server
Dedicated Server
PaaS
Choose a Hosting Plan
Chapter 7Provisioning
Our Goal
Server Setup
PHP-FPM
nginx
Automate Server Provisioning
Delegate Server Provisioning
Further Reading
What’s Next
Chapter 8Tuning
The php.ini File
Memory
Zend OPcache
File Uploads
Max Execution Time
Session Handling
Output Buffering
Realpath Cache
Up Next
Chapter 9Deployment
Version Control
Automate Deployment
Capistrano
Further Reading
What’s Next
Chapter 10Testing
Why Do We Test?
When Do We Test?
What Do We Test?
How Do We Test?
PHPUnit
Continuous Testing with Travis CI
Further Reading
What’s Next
Chapter 11Profiling
When to Use a Profiler
Types of Profilers
Xdebug
XHProf
New Relic Profiler
Blackfire Profiler
Further Reading
What’s Next
Chapter 12HHVM and Hack
HHVM
The Hack Language
Further Reading
Chapter 13Community
Local PUG
Conferences
Mentoring
Stay Up-to-Date
Appendix Installing PHP
Appendix Local Development Environments
Erscheint lt. Verlag | 31.3.2015 |
---|---|
Verlagsort | Sebastopol |
Sprache | englisch |
Maße | 184 x 230 mm |
Gewicht | 454 g |
Einbandart | Paperback |
Themenwelt | Informatik ► Web / Internet ► PHP |
Schlagworte | PHP • PHP, Programmierung, Webprogrammierung, Framework, |
ISBN-10 | 1-4919-0501-8 / 1491905018 |
ISBN-13 | 978-1-4919-0501-2 / 9781491905012 |
Zustand | Neuware |
Haben Sie eine Frage zum Produkt? |
aus dem Bereich