doutan2228 2014-09-29 14:18
浏览 48

Facebook集成PHP(无需打开Facebook页面)

I am implementing the web service for mobile phone(Like ios, adnroid etc). I dont have login/signup through facebook in my App. But i want to share the data from my App to facebook (and twitter ) as a post. For this, i dont want to redirect user to facebook to enter their credentials on facebook and then share the data. My requirement is get only Username and password from the user save it in DB and call the FB API from my webservice which will check for the authentication of the user credentials (Facebook ) and if correct then it will psot the data / message to user FB wall. I am trying with php for this , but all the libraries and codes available, are going for FB login window.

I know that offline facebook access is removed, but still want to go for it.

Please, one guide me for this. Any code for php or code for mobile (Iphone and Android) will work

  • 写回答

1条回答 默认 最新

  • douyi5157 2014-09-29 14:20
    关注

    You can´t use the api with only username and password, that would be a major security problem. If someone hacks your database > access to all Facebook accounts.

    That being said, you don´t need to authorize a user for sharing, the Facebook docs offer a lot of information about that topic: https://developers.facebook.com/docs/sharing

    You can just use the native share dialogs. For posting without a dialog, you would need to do a lot more things:

    And keep in mind that the message parameter must be 100% user generated, see platform policy: https://developers.facebook.com/policy/

    2.3 Ensure that all content in the user message parameter is entered by the user. Don’t pre-fill. This includes posts, messages, comments, and captions.

    A generated message will not get you through the review process.

    评论

报告相同问题?

悬赏问题

  • ¥15 求差集那个函数有问题,有无佬可以解决
  • ¥15 【提问】基于Invest的水源涵养
  • ¥20 微信网友居然可以通过vx号找到我绑的手机号
  • ¥15 寻一个支付宝扫码远程授权登录的软件助手app
  • ¥15 解riccati方程组
  • ¥15 display:none;样式在嵌套结构中的已设置了display样式的元素上不起作用?
  • ¥15 使用rabbitMQ 消息队列作为url源进行多线程爬取时,总有几个url没有处理的问题。
  • ¥15 Ubuntu在安装序列比对软件STAR时出现报错如何解决
  • ¥50 树莓派安卓APK系统签名
  • ¥65 汇编语言除法溢出问题