title: Get user id in case Signed Request - Facebook
body: <p>I know it might be duplicate question but please help. I have created a app and installed it on my Facebook page. My issue when I authenticate it using authentication method I got the user id... But when I go through proper signed request method (i.e. When I login with facebook site only.) I don't get user. how can I get userid in case of signed request that When I login using facebook site.</p>
  
  <p>My signed request. </p>
  
  <pre><code>   $facebook = new Facebook(array(
              'appId' =&gt; '****',
              'secret' =&gt; '****',
              'cookie' =&gt; true,
          ));
  
          echo 'User ID :- ' . $user = $facebook-&gt;getUser();
          $signed_request = $facebook-&gt;getSignedRequest();
  
          echo '&lt;pre&gt;';
          print_r($signed_request);
          echo '&lt;/pre&gt;';
  
  
  User ID :- 0
  Array (
  [algorithm] =&gt; HMAC-SHA256
  [issued_at] =&gt; 1372676199
  [page] =&gt; Array
      (
          [id] =&gt; 544896778905441
          [liked] =&gt; 
          [admin] =&gt; 1
      )
  
  [user] =&gt; Array
      (
          [country] =&gt; in
          [locale] =&gt; en_US
          [age] =&gt; Array
              (
                  [min] =&gt; 21
              )
      )
  )
  </code></pre>
  
  <p>How can I get User id.</p>