From 345d170236572866c0aa29698d5089f4d2bf7c11 Mon Sep 17 00:00:00 2001 From: friendica Date: Fri, 29 Aug 2014 17:31:29 -0700 Subject: doc update --- doc/html/items_8php.html | 26 +++++++++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) (limited to 'doc/html/items_8php.html') diff --git a/doc/html/items_8php.html b/doc/html/items_8php.html index 5e7c4ff11..358d5a31c 100644 --- a/doc/html/items_8php.html +++ b/doc/html/items_8php.html @@ -114,6 +114,8 @@ $(document).ready(function(){initNavTree('items_8php.html','');}); Functions  collect_recipients ($item, &$private_envelope)   + comments_are_now_closed ($item) +   can_comment_on_post ($observer_xchan, $item)    add_source_route ($iid, $hash) @@ -457,7 +459,7 @@ Functions

can_comment_on_post($observer_xchan,$item);

-

This function examines the comment_policy attached to an item and decides if the current observer has sufficient privileges to comment. This will normally be called on a remote site where perm_is_allowed() will not be suitable because the post owner does not have a local channel_id. Generally we should look at the item - in particular the author['book_flags'] and see if ABOOK_FLAG_SELF is set. If it is, you should be able to use perm_is_allowed( ... 'post_comments'), and if it isn't you need to call can_comment_on_post()

+

This function examines the comment_policy attached to an item and decides if the current observer has sufficient privileges to comment. This will normally be called on a remote site where perm_is_allowed() will not be suitable because the post owner does not have a local channel_id. Generally we should look at the item - in particular the author['book_flags'] and see if ABOOK_FLAG_SELF is set. If it is, you should be able to use perm_is_allowed( ... 'post_comments'), and if it isn't you need to call can_comment_on_post() We also check the comments_closed date/time on the item if this is set.

Referenced by Conversation\add_thread(), and item_post().

@@ -525,6 +527,24 @@ Functions

Referenced by notifier_run().

+
+ + +
+
+ + + + + + + + +
comments_are_now_closed ( $item)
+
@@ -1386,7 +1406,7 @@ Functions
-

Referenced by diaspora_asphoto(), diaspora_comment(), diaspora_like(), diaspora_post(), diaspora_reshare(), event_store_item(), item_post(), like_content(), mood_init(), photo_upload(), photos_create_item(), post_activity_item(), process_delivery(), profile_activity(), and subthread_content().

+

Referenced by diaspora_asphoto(), diaspora_comment(), diaspora_like(), diaspora_post(), diaspora_reshare(), element_install(), event_store_item(), item_post(), like_content(), mood_init(), photo_upload(), photos_create_item(), post_activity_item(), process_delivery(), profile_activity(), and subthread_content().

@@ -1733,7 +1753,7 @@ Functions
-

Referenced by item_store(), and item_store_update().

+

Referenced by diaspora_comment(), item_store(), and item_store_update().

-- cgit v1.2.3