2017 © Pedro Peláez
 

library fastcgi

FastCGI protocol, client and server interfaces and implementations

image

appserver-io/fastcgi

FastCGI protocol, client and server interfaces and implementations

  • Tuesday, February 6, 2018
  • by wagnert
  • Repository
  • 1 Watchers
  • 1 Stars
  • 5,717 Installations
  • PHP
  • 3 Dependents
  • 0 Suggesters
  • 8 Forks
  • 0 Open issues
  • 8 Versions
  • 2 % Grown

The README.md

Fork of [https://github.com/CrunchPHP/fastcgi], (*1)

FastCGI client library, (*2)

Allows to access a FastCGI-server directly from PHP., (*3)

  • Subrequest
  • Testing (fetch pages as seen by the webserver)
  • Background tasks

Usage

Preparation, (*4)

require __DIR__ . '/../vendor/autoload.php';
use Crunch\FastCGI\Client as FastCGI;

$fastCgi = new FastCGI('unix:///var/run/php5-fpm.socket', null);
// $fastCgi = new FastCGI('localhost', 9999);
$connection = $fastCgi->connect();

The request, (*5)

$request = $connection->newRequest();
$request->parameters = array(
    'GATEWAY_INTERFACE' => 'FastCGI/1.0',
    'REQUEST_METHOD' => 'POST',
    'SCRIPT_FILENAME' => '/var/www/example.php',
    'CONTENT_TYPE' => 'application/x-www-form-urlencoded',
    'CONTENT_LENGTH' => strlen('foo=bar')
);
$request->stdin = 'foo=bar';

Single request and response, (*6)

$response = $connection->request($request);
echo $response->content;

Background (includes multiplexing), (*7)

$connection->sendRequest($request);
// Many code
$response = $connection->receiveResponse($request);

Requirements

  • PHP => 5.3

Contributors

See CONTRIBUTING.md for details on how to contribute., (*8)

License

This library is licensed under the MIT License. See the LICENSE file for details., (*9)

The Versions

06/02 2018

2.x-dev

2.9999999.9999999.9999999-dev

FastCGI protocol, client and server interfaces and implementations

  Sources   Download

MIT

The Requires

 

server client fastcgi protocol

06/02 2018

v2.0.0

2.0.0.0

FastCGI protocol, client and server interfaces and implementations

  Sources   Download

MIT

The Requires

 

server client fastcgi protocol

13/12 2015

dev-master

9999999-dev

fastcgi client

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

The Development Requires

fastcgi

23/02 2015

1.0.1

1.0.1.0 http://crunchfastcgi.readthedocs.org/en/latest/

fastcgi client

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

The Development Requires

fastcgi

13/02 2015

1.0.0

1.0.0.0 http://crunchfastcgi.readthedocs.org/en/latest/

fastcgi client

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

The Development Requires

fastcgi

20/12 2014
15/07 2014

0.1.1

0.1.1.0 http://crunchfastcgi.readthedocs.org/en/latest/

FastCGI client

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

The Development Requires

fastcgi

26/06 2013

v0.1

0.1.0.0 http://crunchfastcgi.readthedocs.org/en/latest/

FastCGI client

  Sources   Download

MIT

The Requires

  • php >=5.3.0

 

fastcgi