Documentation in progress
Request is designed to be the simplest way possible to make http calls in PHP.
require 'phprequest.php';
$request = new Request();
$res = $request->get('http://www.google.com');
if (!$res['error'] && $res['statuscode'] == 200) {
echo $res['body']; // Show the HTML for the Google homepage.
}
else {
echo $res['error'];
}
- Request defaults
- Request response
- Post
- Get
- Patch
- Delete
- Custom request
- Response type
- Custom HTTP Headers