title: How can I display the users profile pic using the facebook graph api?
body: <p>I would like to display the users profile picture inside of my applications canvas page, is there a way to do that using the graph api?</p>
  
  <p>I know I can do it using FBML but I would also like to pass the profile pic to a flash game I am making, so I would have to get the profile pic from the api and send it as a variable, here is the code I have thus far,</p>
  
  <pre><code>$facebook = new Facebook(array(
      'appId'  =&gt; FACEBOOK_APP_ID,
      'secret' =&gt; FACEBOOK_SECRET_KEY,
      'cookie' =&gt; true,
      'domain' =&gt; 'myurl/facebook-test'
  ));
  
  $session = $facebook-&gt;getSession();
  
          $uid = $facebook-&gt;getUser();
          $me = $facebook-&gt;api('/me');
  
          $updated = date("l, F j, Y", strtotime($me['updated_time']));
  
          echo "Hello " . $me['name'] . $me['picture'] . "&lt;br /&gt;";
    echo "&lt;div style=\"background:url(images/bg.jpg); width:760px; height:630px;\"&gt;" . "You last updated your profile on " . $updated . "&lt;/div&gt;" . "&lt;br /&gt; your uid is" . $uid;
  </code></pre>
  
  <p><code>$me['picture']</code> does not seem to be working, but I am still very new to the graph api, and I am probably making a few very amateur mistakes!</p>