duanao4503 2011-11-30 12:29
浏览 73
已采纳

如何从FQL获得100x100px和200x200px个人资料图片?

i am using this fql query this gives me 50x50px profile pic of user's friend

$FQLQuery = 'SELECT uid,sex,pic_square FROM user WHERE uid in (SELECT uid2 FROM friend WHERE uid1 = me())';

i want to get 100x100px or 200x200px by using fql only.

how i can get that?

  • 写回答

4条回答 默认 最新

  • douweibiao8471 2013-04-22 18:48
    关注

    I get the avatar using graph API by the following

    $request_url ="https://graph.facebook.com/" .
        $parfbuid . "?fields=picture.width(200).height(200)";
    $requests = file_get_contents($request_url);    
    $data = json_decode($requests);
    $fsource = $data->picture->data->url;
    $size=getimagesize($fsource);
    

    and then I use GD library to get this image and save on disk. This way you can get whatever size you like of the rectangle avatar image.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(3条)

报告相同问题?

悬赏问题

  • ¥66 比特币地址如何生成taproot地址
  • ¥20 数学建模数学建模需要
  • ¥15 关于#lua#的问题,请各位专家解答!
  • ¥15 什么设备可以研究OFDM的60GHz毫米波信道模型
  • ¥15 不知道是该怎么引用多个函数片段
  • ¥30 关于用python写支付宝扫码付异步通知收不到的问题
  • ¥50 vue组件中无法正确接收并处理axios请求
  • ¥15 隐藏系统界面pdf的打印、下载按钮
  • ¥15 基于pso参数优化的LightGBM分类模型
  • ¥15 安装Paddleocr时报错无法解决