title: how to use cURL in facebook graph api request
body: <p>I am getting the information to facebook graph api using file_get_contents()</p>
  
  <p>but sometimes I am receiving an error.</p>
  
  <p>I found out that cURL must be used instead of file_get_contents().</p>
  
  <p>The problem is, I don't know how to use cURL with the URL that I need to pass.</p>
  
  <p>if I converted</p>
  
  <pre><code>file_get_contents($graph_url);
  </code></pre>
  
  <p>into cURL, what will be the code?</p>
  
  <p>here is the content of $graph_url</p>
  
  <pre><code>$graph_url= "https://graph.facebook.com/me/photos?"
    . "url=" . urlencode($photo_url)
    . "&amp;message=" . urlencode('')
    . "&amp;method=POST"
    . "&amp;access_token=" .$access_token;
  </code></pre>