[ Index ]

PHP Cross Reference of BuddyPress

title

Body

[close]

/src/bp-groups/ -> bp-groups-forums.php (summary)

BuddyPress Groups Forums. Action functions are exactly the same as screen functions, however they do not have a template screen associated with them. Usually they will send the user back to the default screen after execution.

File Size: 654 lines (23 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 10 functions

  groups_new_group_forum()
  groups_update_group_forum()
  groups_new_group_forum_post()
  groups_new_group_forum_topic()
  groups_update_group_forum_topic()
  groups_update_group_forum_post()
  groups_delete_group_forum_topic()
  groups_delete_group_forum_post()
  groups_total_public_forum_topic_count()
  groups_total_forum_topic_count()

Functions
Functions that are not part of a class:

groups_new_group_forum( $group_id = 0, $group_name = '', $group_desc = '' )   X-Ref
Creates a new forum inside a specific BuddyPress group.

Uses the bundled version of bbPress packaged with BuddyPress.

param: int    $group_id   The group ID that the new forum should be attached to.
param: string $group_name The group name.
param: string $group_desc The group description.
since: 1.0.0

groups_update_group_forum( $group_id )   X-Ref
Update group forum metadata (title, description, slug) when the group's details are edited.

param: int $group_id Group id, passed from groups_details_updated.
return: false|null
since: 1.1.0

groups_new_group_forum_post( $post_text, $topic_id, $page = false )   X-Ref
Create a new group forum post.

Uses the bundled version of bbPress packaged with BuddyPress.

param: string $post_text The text for the forum post.
param: int    $topic_id  The topic ID used so we can identify where the new
param: mixed  $page      The page number where the new forum post should reside.
return: mixed The new forum post ID on success. Boolean false on failure.
since: 1.0.0

groups_new_group_forum_topic( $topic_title, $topic_text, $topic_tags, $forum_id )   X-Ref
Create a new group forum topic.

Uses the bundled version of bbPress packaged with BuddyPress.

param: string $topic_title The title for the forum topic.
param: string $topic_text  The text for the forum topic.
param: string $topic_tags  A comma-delimited string of topic tags.
param: int    $forum_id    The forum ID this forum topic resides in.
return: mixed The new topic object on success. Boolean false on failure.
since: 1.0.0

groups_update_group_forum_topic( $topic_id, $topic_title, $topic_text, $topic_tags = false )   X-Ref
Update an existing group forum topic.

Uses the bundled version of bbPress packaged with BuddyPress.

param: int    $topic_id    The topic ID of the existing forum topic.
param: string $topic_title The title for the forum topic.
param: string $topic_text  The text for the forum topic.
param: mixed  $topic_tags  A comma-delimited string of topic tags. Optional.
return: mixed The topic object on success. Boolean false on failure.
since: 1.1.0

groups_update_group_forum_post( $post_id, $post_text, $topic_id, $page = false )   X-Ref
Update an existing group forum post.

Uses the bundled version of bbPress packaged with BuddyPress.

param: int    $post_id   The post ID of the existing forum post.
param: string $post_text The text for the forum post.
param: int    $topic_id  The topic ID of the existing forum topic.
param: mixed  $page      The page number where the new forum post should reside. Optional.
return: mixed The forum post ID on success. Boolean false on failure.
since: 1.1.0

groups_delete_group_forum_topic( $topic_id )   X-Ref
Delete a group forum topic and also any corresponding activity items.

Uses the bundled version of bbPress packaged with BuddyPress.

param: int $topic_id The ID of the topic to be deleted.
return: bool True if the delete routine went through properly.
since: 1.1.0

groups_delete_group_forum_post( $post_id, $topic_id = false )   X-Ref
Delete a group forum post and its corresponding activity item.

Uses the bundled version of bbPress packaged with BuddyPress.

param: int      $post_id  The ID of the post you want to delete.
param: int|bool $topic_id Optional. The topic to which the post belongs. This
return: bool True on success.
since: 1.1.0

groups_total_public_forum_topic_count( $type = 'newest' )   X-Ref
Get a total count of all public topics of a given type, across groups/forums.

param: string $type Either 'newest', 'popular', 'unreplied', 'tags'.
return: int The topic count.
since: 1.5.0

groups_total_forum_topic_count( $status = 'public', $search_terms = false )   X-Ref
Get a total count of all topics of a given status, across groups/forums.

param: string      $status       Which groups to count. 'public', 'private', 'hidden',
param: string|bool $search_terms Optional. Limit by a search term.
return: int The topic count.
since: 1.5.0



Generated: Thu Dec 7 01:01:35 2017 Cross-referenced by PHPXref 0.7.1