title: Get JSON response from facebook api restserver
body: <p>I want to get the like_count of a page.  I tried using PHP SDK, but I've given up on it because my site always stops loading after the line of code where the FQL query is executed, so I wanted to try to get the like count 'manually'.</p>
  
  <p>I tried using file_get_contents() on <a href="https://api.facebook.com/restserver.php?method=fql.query&amp;query=QUERY&amp;format=json" rel="nofollow noreferrer">https://api.facebook.com/restserver.php?method=fql.query&amp;query=QUERY&amp;format=json</a>, but it shows me nothing.</p>
  
  <p>Do you know how I can get the JSON string from the above URL on which I can use json_decode(), <strong>or even a better way to get the like count</strong>?</p>
  
  <p>Any help is appreciated.</p>
  
  <p>PS If it means anything, QUERY is SELECT like_count FROM link_stat WHERE url="page_url_here"</p>