久久久久久久av_日韩在线中文_看一级毛片视频_日本精品二区_成人深夜福利视频_武道仙尊动漫在线观看

Facebook SDK 和 Graph API 評論刪除錯誤

Facebook SDK and Graph API Comment Deleting Error(Facebook SDK 和 Graph API 評論刪除錯誤)
本文介紹了Facebook SDK 和 Graph API 評論刪除錯誤的處理方法,對大家解決問題具有一定的參考價值,需要的朋友們下面隨著小編來一起學習吧!

問題描述

使用 Facebook php SDK 時,考慮到評論的 id 和 xid,我在弄清楚如何刪除評論時遇到了很多麻煩.

Working with the Facebook php SDK's, I am having a lot of trouble figuring out how to delete comments, given its id and xid.

起初我使用的是 REST API,您可以在其中調用 'comments_remove($xid, $id);'刪除評論.當 xid 參數只接受字母數字字符和下劃線時,此方法就會出現問題.基于文檔 (http://developers.facebook.com/docs/reference/fbml/comments ) 一個有效的 XID 可以是任何 url_encode 的結果.

At first I was using the REST API, where you can call 'comments_remove($xid, $id);' to delete a comment. The problem with this method came when the xid parameter only accepts alphanumeric characters and underscores. Based on the documentation (http://developers.facebook.com/docs/reference/fbml/comments ) a valid XID can be the result of any url_encode.

現在我正在使用新的 GRAPH api 測試我的運氣.在刪除對象"下查看 http://developers.facebook.com/docs/api, 看來是肯定支持刪除評論了.但是,我嘗試發送 DELETE 請求,并且還嘗試使用參數method=delete"向對象 url 發送 POST 和 GET.

Now I am testing my luck with the new GRAPH api. Looking at http://developers.facebook.com/docs/api under 'Deleting Objects', It seems that comment deleting is definitely supported. However, I have tried sending a DELETE request, and I have also tried sending POST and GET to the object url with the argument 'method=delete'.

不管我怎么嘗試,我總是得到同樣的錯誤:

No matter how I try it, I always get the same error:

{"error":{"type":"GraphMethodException","message":"不支持的刪除請求."}}

{"error":{"type":"GraphMethodException","message":"Unsupported delete request."}}

我也將訪問令牌作為參數發送.我發送的訪問令牌是從 javascript cookie 上的單點登錄保存在 facebook cookie 中的訪問令牌.這些都是對我的申請的評論.這是否發生在其他人身上,或者我只是做錯了?

I am sending the access token as a parameter as well. The access token that I am sending is the access token saved in the facebook cookie from the single sign on javascript cookie. These are all comments made on my application. Does this happen to anyone else, or am I simply not doing this right?

非常感謝任何幫助或指導.

Any help or guidance is GREATLY appreciated.

推薦答案

已修復!

刪除時必須在對象 ID 前面加上用戶 ID:

You have to prepend the userid to the object ID when deleting:

刪除https://graph.facebook.com/673509687_104812882909249?access_token?access_token}在哪里673509687 是我的用戶 ID,104812882909249 是對象 ID

DELETE https://graph.facebook.com/673509687_104812882909249?access_token={access_token} where 673509687 is my userID and 104812882909249 is the objectID

這篇關于Facebook SDK 和 Graph API 評論刪除錯誤的文章就介紹到這了,希望我們推薦的答案對大家有所幫助,也希望大家多多支持html5模板網!

【網站聲明】本站部分內容來源于互聯網,旨在幫助大家更快的解決問題,如果有圖片或者內容侵犯了您的權益,請聯系我們刪除處理,感謝您的支持!

相關文檔推薦

Joining 2 tables in SELECT(MYSQL/PHP)(在 SELECT(MYSQL/PHP) 中加入 2 個表)
How to make lt;option selected=quot;selectedquot;gt; set by MySQL and PHP?(如何使lt;option selected=“selectedgt;由 MySQL 和 PHP 設置?)
Auto populate a select box using an array in PHP(使用 PHP 中的數組自動填充選擇框)
PHP SQL SELECT where like search item with multiple words(PHP SQL SELECT where like search item with multiple words)
json_encode produce JSON_ERROR_UTF8 from MSSQL-SELECT(json_encode 從 MSSQL-SELECT 產生 JSON_ERROR_UTF8)
MySQL ORDER BY rand(), name ASC(MySQL ORDER BY rand(),名稱 ASC)
主站蜘蛛池模板: 成人一级视频在线观看 | 亚洲国产成人av好男人在线观看 | 国产在线精品一区二区 | 日韩字幕一区 | 精品av久久久久电影 | 久久综合一区 | 国产精品免费一区二区三区 | 亚洲电影中文字幕 | 99re热精品视频 | 国产精品欧美精品 | 三级特黄特色视频 | 国产亚洲成av人片在线观看桃 | 国产精品久久久亚洲 | 国产精品久久久久久一级毛片 | 欧美日韩在线免费 | 国产精品欧美一区二区三区不卡 | 欧美精品久久久久 | 欧美福利视频 | 成人午夜 | 精品在线免费看 | 久久久成人精品 | 欧美在线a | 亚洲精品一区二区 | 国产精品高清一区二区 | 毛片高清 | 亚洲一区二区在线播放 | 国内精品免费久久久久软件老师 | 日本三级做a全过程在线观看 | 亚洲视频在线一区 | 精品国产乱码久久久久久丨区2区 | 91精品国产91久久久久游泳池 | 中文字幕av免费 | 麻豆av电影网 | 精品亚洲永久免费精品 | 亚洲人人| 久久av一区二区三区 | 国产乱码久久久 | 欧美一区二区在线播放 | 精产国产伦理一二三区 | 欧美a∨| 午夜视频免费网站 |