title: URL requests in php?
body: <p>I am looking at an API that I would like to use and am having a hard time figuring out how to use it. This API needs me to give URL requests to a website and it will respond with JSON data. An example request that they give is:</p>
  
  <pre><code> curl -i -H "X-Accept-Datetime-Format: UNIX" "https://api-fxpractice.oanda.com/v1/candles?instrument=EUR_USD&amp;start=137849394&amp;count=1"
  </code></pre>
  
  <p>I can not figure out how to make a request like this in a php script. I have looked at many websites but I still don't understand what the -i and the -H are used for. Furthermore I am having trouble finding a website that will explain how the data :<code>"X-Accept-Datetime-Format: UNIX"</code> is supposed to be sent to a website through a URL request in php. All help in finding a website that will better explain what all of this means and how I can create a php script to run this will be very helpful. Thank you very much for your help!</p>