Facebook Graph API 不返回事件图片 [英] Facebook Graph API does not return the event picture

查看:31
本文介绍了Facebook Graph API 不返回事件图片的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

似乎 Facebook 终于修复了这个错误!

Seems like Facebook finally fixed this bug!

你能帮我理解为什么会这样吗:

Could you help me understand why this is happening:

这是一个带有图片的公共活动:https://www.facebook.com/events/282054218538223

This is a public event with a picture: https://www.facebook.com/events/282054218538223

但是当我尝试访问 http://graph.facebook.com/282054218538223/picture,我得到的只是默认图片.

But when I try to access http://graph.facebook.com/282054218538223/picture, all I get is a default picture.

这是另一个公开活动:http://www.facebook.com/events/266496120103339

但这一次,访问http://graph.facebook.com/266496120103339/picture返回活动照片.

But this time, accessing http://graph.facebook.com/266496120103339/picture returns the event photo.

这两个事件有什么区别?

What's the difference between the 2 events?

推荐答案

这个答案没有解释为什么请求在使用 Graph API 时不起作用,但可能会帮助需要检索事件的人个人资料图片.

This answer doesn't explain why the request doesn't work using Graph API but might help someone who needs to to retrieve event profile images.

使用 FQL,您可以像这样检索事件配置文件图像:

With FQL you can retrieve the event profile image like this:

SELECT pic, pic_small, pic_big FROM event WHERE eid=282054218538223

SELECT pic, pic_small, pic_big FROM event WHERE eid=282054218538223

使用 Robin 的第一个示例中的事件 ID.此调用以 3 种不同大小返回事件配置文件图像的 URL.它适用于 Robin 问题中的两个示例,只需更改事件 ID.

using the event id from Robin's first example. This call returns urls to the event profile image in 3 different sizes. It works for both examples in Robin's question, just change the event id.

Graph Explorer 中尝试使用 Robin 的示例:

Try it in Graph Explorer with Robin's example:

https://graph.facebook.com/fql?q=SELECT pic,pic_big,pic_small FROM event WHERE eid=282054218538223

和 MoXplod 的例子:

and MoXplod's example:

https://graph.facebook.com/fql?q=SELECT pic,pic_big,pic_small FROM event WHERE eid=271148229633674

如果需要,请确保您拥有访问令牌,如FQL 事件表中所述.

Make sure you have access token if needed as outlined in the FQL event table.

这篇关于Facebook Graph API 不返回事件图片的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆