| FBML has been deprecated. Starting June 1, 2012 FBML apps will no longer work as all FBML endpoints will be removed. If you are building a new application on Facebook.com, please implement your application using HTML, JavaScript and CSS. You can use our JavaScript SDK and Social Plugins to embedded many of the same social features available in FBML. |
Displays a set of comments for a unique identifier. Facebook handles posting, drawing, and see all page.
The fb:comments tag is essentially a Wall for developers to drop on canvas pages and application tabs on profiles easily. Using the tag implies a Wall-like comments set exists that can be posted or identified by the passed XID. Please note the following:
callbackurl supplied. The callbackurl defaults to the page where it was originally found, so the tag should work without any extra coding. However, you can point a callbackurl to a special page that can be more efficient.callbackurl.fb_sig_xid parameter is passed to these pages. Facebook looks for this xid. You can use it to short-circuit your application logic and only output the fb:comments tag with the proper parameters.fb_sig_xid_action parameter. Currently this can be "post" or "delete". If you return true for the action requested in the fb:comments tag, you can assume the action was performed.callbackurl, mimicking a canvas page.simple attribute below.numposts to 0. This hides all comments. You can then use comments.get to retrieve all your comments and moderate or filter them as needed.| Name | Type | Description |
|---|---|---|
| xid | string | The unique identifier for this set of comments. XIDs can contain alphanumeric characters (Aa-Zz, 0-9), hyphens (-), percent (%), period (.), and underscores (_) (in effect, the result of any urlencode can be a valid XID). |
| canpost | bool | Indicates whether the viewing user can post on this comment set. |
| candelete | bool | Indicates whether the viewing user can delete any post on this comment set. Any user visiting that user's profile where the comment appears can delete comments made to it (so, avoid using candelete unless this is the intended functionality). |
| numposts | int | The maximum number of posts to display. You can set numposts to 0 to not display any comments, for moderation purposes. Default value is 10 |
| callbackurl | string | The URL to refetch this configuration. Default value is the current page |
| returnurl | string | The URL where the user is returned after selecting a "back" link. Default value is the current page |
| showform | bool | Boolean whether to show the form (canpost "true" only) for inline posting. Posts using this form will not go to a see-all page after posting, but rather refresh the page. |
| send_notification_uid | int | User ID to send a notification to upon someone posting a comment. (Only one |
| publish_feed | bool | Indicates whether to publish a Feed story when the comment gets posted. The comment must be at least 5 words in length in order to be published to Feed. |
| simple | bool | Removes the rounded box around the text area to allow greater customization. |
| reverse | bool | Changes the order of comments and comment area to allow greater customization. |
<fb:comments xid="titans_comments" canpost="true" candelete="false" returnurl="http://apps.facebook.com/myapp/titans/"> <fb:title>Talk about the Titans</fb:title> </fb:comments>
[[Fb:comments Snippet - Tracking comment count|Code Snippet - Tracking the Comment Count]]