19/09
2017
PHP curl helper
PHP curl request hepler, (*1)
Handle HTTP requests to the REST API, (*2)
Use composer, (*3)
composer require enumit/curl
$curlHelper = new \enumit\curl\CurlHelper(); $res = $curlHelper->setUrl('https://api.mydomain.com/order') ->setRequestMethod('PUT') ->setHeader(['Content-Type: application/json']) ->setQueryData(['order_number'=>'123456', 'amount'=>'154.33']) ->send();