zlik / http-status-codes-trait
A PHP trait which defines all standard HTTP status codes.
Installs: 225
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/zlik/http-status-codes-trait
Requires
- php: >=5.4.0
This package is auto-updated.
Last update: 2025-10-13 06:52:02 UTC
README
#HTTP Status Codes Trait
A PHP trait which defines all standard HTTP status codes.
#Installing with Composer
"require": { "zlik/http-status-codes-trait": "1.0" }
#Usage
Mix the \Zlik\HttpStatusCodes
trait into your class and utilize it's public properties to get HTTP status codes.
For example:
class Foo { use \Zlik\HttpStatusCodes; } $foo = new Foo; echo $foo->HTTP_NOT_FOUND; //outputs '404'
#Requirements
PHP 5.4+