简体   繁体   中英

Recommendations Bar: Remove read action (remove from my timeline)

The Recommendations Bar seems to work well, but there is not an ability to remove the most recent read action from a user's timeline. As all of the actions are handled by the plugin, there doesn't seem to be a way to get the ACTION_ID generated by the Read.

As such, Facebook will not approve my Read Action with the Recommendation Bar because I can't provide a link in the article that says "Remove from Timeline" that deletes the action from a user's timeline.

您以url为对象,读取了read操作的/me/news.reads API调用,然后使用该操作ID进行删除。

I've had the same problem in getting my read action approved. Unfortunately, Facebook doesn't care and will reject your action on the basis that it doesn't provide the user the ability to later delete their actions.

The only way is to build this functionality in manually. The Recommendation Bar Plugin doesn't return the ID for the action after it has been posted to Facebook so you would have to manually query Facebook to get the information back:

$activity = $fb->api('/me/' . $action_id );
print_r( $activity );

You will then have to display the information correct and let the user delete their information from there.

For my site, I had to create a WordPress plugin to do just that. You can see it in action here: http://www.xtremeps3.com/wp-admin/admin.php?page=facebook-activity/facebook-activity.php

And just as an update, the "social reading" function of the Recommendation Bar has been removed, probably due to the Read action issues (which were reported as a bug several months ago and marked as fixed at the same time as the feature disappeared). It just replicates the Recommend Box functionality now.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM