library httpserver
Wrapper around PHP 5.4's HTTP Server.
robloach/httpserver
Wrapper around PHP 5.4's HTTP Server.
- Thursday, October 11, 2012
- by RobLoach
- Repository
- 1 Watchers
- 4 Stars
- 1 Installations
- PHP
- 0 Dependents
- 0 Suggesters
- 0 Forks
- 0 Open issues
- 1 Versions
- 0 % Grown
HttpServer
A wrapper around PHP 5.4's HTTP Server., (*1)
Requirements
Installation
In your composer.json, add the following:, (*2)
"require" {
"robloach/httpserver": "*"
}
Usage
// Set up the HTTP web server.
$server = new HttpServer\HttpServer('/var/www', 'localhost', 8080);
$server->start();
// Do something with it.
$contents = file_get_contents('http://localhost:8080/example.php');
// Now that we've done something, let's shut it down.
$server->stop();
Testing
php composer.phar install --dev
php vendor/bin/phpunit
dev-master
9999999-dev
Wrapper around PHP 5.4's HTTP Server.
Sources
Download
MIT
The Requires
The Development Requires