Facebook Graph API will not give me picture data

后端 未结 6 760
傲寒
傲寒 2021-01-12 22:59

Using PHP 5.2.11 and the new facebook graph code...

If I call

$facebook->api(\"/me\");

I get a proper response:

array
  \'id\' =>          


        
6条回答
  •  暖寄归人
    2021-01-12 23:23

    While using $facebook->api("/me?fields=picture"); does work, you won't be able to pass parameters such as width or type. Instead try the following:

    $facebook->api('/me/picture?redirect=false');
    

    This worked for me and will also allow you to pass parameters.

提交回复
热议问题