There is a sniff for PHP_CodeSniffer to checks for HTTP extension compatibility between 1.x and 2.x versions, useful for version migrations, scanning your code looking for forbidden functions and classes.

For all those who still have code using the old pecl_http1 API and want to use PHP 5.6, you may want to make a wrapper on top of pecl_http2.

The following code will work with PHP 5.6 if you use a wrapper:<?php$r = new HttpRequest($post_url, HttpRequest::METH_POST);$r->setHeaders(array('User-Agent' => $user_agent));$r->addPostFields($post_data);try {$r->send(); if ($r->getResponseCode() == 200) { echo $r->getResponseBody(); }} catch (HttpException $ex) {// catch exception}?>

Here is the code of the wrapper of HttpRequst on top of pecl_http2 with PHP 5.6:<?phpclass HttpRequest { private $url; private $method; private $headers; private $post_fields;