Coroutine\Http\Client->post

发起POST请求,函数原型:

function Swoole\Coroutine\Http\Client->post(string $path, mixed $data);

使用实例

$cli = new Swoole\Coroutine\Http\Client('127.0.0.1', 80); 
$cli->post('/post.php', array("a" => '1234', 'b' => '456'));
echo $cli->body;
$cli->close();