PHP code example of mjelamanov / psr17-httplug

1. Go to this page and download the library: Download mjelamanov/psr17-httplug library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

mjelamanov / psr17-httplug example snippets

 php
use Mjelamanov\Psr17Httplug\ResponseFactory;
use Http\Message\StreamFactory\GuzzleMessageFactory; // A php-http's response factory implementation

$responseFactory = new ResponseFactory(new GuzzleMessageFactory());

$response = $responseFactory->createResponse(200, 'OK');