The PHP Standard Recommendation (PSR) is a PHP specification published by the PHP Framework Interop Group. Similar to Java Specification Request for Java, it serves the standardization of programming concepts in PHP. The aim is to enable interoperability of components and to provide a common technical basis for implementation of proven concepts for optimal programming and testing practices. The PHP-FIG is formed by several PHP frameworks founders.
Each PSR is suggested by members and voted according to an established protocol to act consistently and in line with their agreed upon processes.
Number Name Description Editor Coordinator Sponsor Status PSR-0 Autoloading Standard It describes the mandatory requirements that must be adhered to for autoloader interoperability. Deprecated and substituted by PSR-4 PSR-1 Basic Coding Standard It comprises what should be considered the standard coding elements that are required to ensure a high level of technical interoperability between shared PHP code. Accepted PSR-2 Coding Style Guide It considers PSR-1 and it is intended to reduce cognitive friction when scanning code from different authors. It does so by enumerating a shared set of rules and expectations about how to format PHP code. Deprecated PSR-3 Logger Interface It describes a common interface for logging libraries. Jordi Boggiano Accepted PSR-4 Autoloading Standard It describes a specification for autoloading classes from file paths. It is fully interoperable, and can be used in addition to any other autoloading specification, including PSR-0. This PSR also describes where to place files that will be auto loaded according to the specification. Paul M. Jones Phil Sturgeon Larry Garfield Accepted PSR-5 PHPDoc Standard The main purpose of this PSR is to provide a complete and formal definition of the PHPDoc standard. This PSR deviates from its predecessor, the de facto PHPDoc Standard associated with phpDocumentor 1.x, to provide support for newer features in the PHP language and to address some of the shortcomings of its predecessor. Mike van Riel Phil Sturgeon Donald Gilbert Draft PSR-6 Caching Interface The goal of this PSR is to allow developers to create cache-aware libraries that can be integrated into existing frameworks and systems without the need for custom development. Larry Garfield Paul Dragoonis Robert Hafner Accepted PSR-7 HTTP Message Interface It describes common interfaces for representing HTTP messages as described in RFC 7230 and RFC 7231, and URIs for use with HTTP messages as described in RFC 3986. Matthew Weier O'Phinney Beau Simensen Paul M. Jones Accepted PSR-8 Huggable Interface It establishes a common way for objects to express mutual appreciation and support by hugging. This allows objects to support each other in a constructive fashion, furthering cooperation between different PHP projects. Larry Garfield Cal Evans Paul M. Jones Abandoned PSR-9 Security Disclosure It gives project leads a clearly defined approach to enabling end users to discover security disclosures using a clearly defined structured format for these disclosures. Lukas Kahwe Smith Korvin Szanto Larry Garfield Abandoned PSR-10 Security Advisories It gives researchers, project leads, upstream project leads and end users a defined and structured process for disclosing security vulnerabilities. Lukas Kahwe Smith Larry Garfield Korvin Szanto Abandoned PSR-11 Container Interface It describes a common interface for dependency injection containers. The goal is to standardize how frameworks and libraries make use of a container to obtain objects and parameters (called entries in the rest of this document). Matthieu Napoli, David Négrier Paul M. Jones Jeremy Lindblom AcceptedPSR-12 Extended Coding Style Guide It extends, expands and replaces PSR-2, the coding style guide and requires adherence to PSR-1, the basic coding standard. Michael CullumKorvin SzantoAlexander MakarovAcceptedPSR-13Hypermedia LinksIt describes common interfaces for representing a hypermedia link.Larry GarfieldMatthew Weier O’PhinneyMarc AlexanderAcceptedPSR-14Event ManagerIt describes common interfaces for dispatching and handling events.Larry GarfieldAcceptedPSR-15HTTP Server Request HandlersIt describes common interfaces for HTTP server request handlers and HTTP server middleware components that use HTTP messages.Woody GilkMatthew Weier O’PhinneyAcceptedPSR-16Simple CacheIt describes a simple yet extensible interface for a cache item and a cache driver.Paul DragoonisJordi BoggianoFabien PotencierAcceptedPSR-17HTTP FactoriesIt describes a common standard for factories that create PSR-7 compliant HTTP objects.Woody GilkMatthew Weier O’PhinneyAcceptedPSR-18HTTP ClientIt describes a common interface for sending HTTP requests and receiving HTTP responses.Tobias NyholmSara GolemonAcceptedPSR-19PHPDoc tagsIt provides a complete catalog of tags in the PHPDoc standard.Chuck BurgessDraftPSR-20ClockIt provides a standard way of accessing the clock - allowing interopability during testing, when testing behavior that has timing based side effects.Chris SeufertChuck BurgessAcceptedPSR-21InternationalizationTBD.Navarr BarnierDraftPSR-22Application TracingTBD.Adam AllportDraft
The PHP-FIG official website has the PSR documentation that follows the RFC 2119 written by Scott Bradner in March 1997 at Harvard University.
References
External links PHP Framework Interop Group official website