get.php 325 B

12345678910111213
  1. <?php
  2. // First, include Requests
  3. include('../library/Requests.php');
  4. // Next, make sure Requests can load internal classes
  5. Requests::register_autoloader();
  6. // Now let's make a request!
  7. $request = Requests::get('http://httpbin.org/get', array('Accept' => 'application/json'));
  8. // Check what we received
  9. var_dump($request);