Changeset 2993 for branches/plugin/bbp-includes/bbp-forum-template.php
- Timestamp:
- 04/12/2011 03:42:06 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/plugin/bbp-includes/bbp-forum-template.php
r2981 r2993 11 11 12 12 /** 13 * Return the unique IDof the custom post type for forums13 * Output the unique id of the custom post type for forums 14 14 * 15 15 * @since bbPress (r2857) 16 * 17 * @global bbPress $bbp 18 * @return string 16 * @uses bbp_get_forum_post_type() To get the forum post type 19 17 */ 20 18 function bbp_forum_post_type() { … … 22 20 } 23 21 /** 24 * Return the unique IDof the custom post type for forums22 * Return the unique id of the custom post type for forums 25 23 * 26 24 * @since bbPress (r2857) 27 25 * 28 * @global bbPress $bbp 29 * @return string 26 * @uses apply_filters() Calls 'bbp_get_forum_post_type' with the forum 27 * post type id 28 * @return string The unique forum post type id 30 29 */ 31 30 function bbp_get_forum_post_type() { 32 31 global $bbp; 32 33 33 return apply_filters( 'bbp_get_forum_post_type', $bbp->forum_post_type ); 34 34 } … … 45 45 * @param mixed $args All the arguments supported by {@link WP_Query} 46 46 * @uses WP_Query To make query and get the forums 47 * @uses bbp_get_forum_post_type() To get the forum post type id 48 * @uses bbp_get_forum_id() To get the forum id 49 * @uses get_option() To get the forums per page option 47 50 * @uses current_user_can() To check if the current user is capable of editing 48 51 * others' forums … … 132 135 * @uses bbp_is_topic() To check if it's a topic page 133 136 * @uses bbp_get_topic_forum_id() To get the topic forum id 134 * @uses apply_filters() Calls 'bbp_get_forum_id' with the forum id 135 * @return int Forum id 137 * @uses get_post_field() To get the post's post type 138 * @uses apply_filters() Calls 'bbp_get_forum_id' with the forum id and 139 * supplied forum id 140 * @return int The forum id 136 141 */ 137 142 function bbp_get_forum_id( $forum_id = 0 ) { … … 393 398 * @param int $forum_id Optional. Forum id 394 399 * @uses bbp_get_forum_id() To get the forum id 400 * @uses bbp_get_forum_last_active_id() To get the forum last active id 401 * @uses bbp_get_forum_last_reply_id() To get the forum last reply id 402 * @uses bbp_get_forum_last_topic_id() To get the forum last topic id 395 403 * @uses bbp_get_forum_last_reply_url() To get the forum last reply url 396 404 * @uses bbp_get_forum_last_reply_title() To get the forum last reply 397 405 * title 398 * @uses bbp_get_forum_last_active_time() To get the time when the forum was 399 * last active 406 * @uses bbp_get_forum_last_topic_permalink() To get the forum last 407 * topic permalink 408 * @uses bbp_get_forum_last_topic_title() To get the forum last topic 409 * title 410 * @uses bbp_get_forum_last_active_time() To get the time when the forum 411 * was last active 400 412 * @uses apply_filters() Calls 'bbp_get_forum_freshness_link' with the 401 413 * link and forum id 402 414 */ 403 415 function bbp_get_forum_freshness_link( $forum_id = 0 ) { 404 $forum_id = bbp_get_forum_id( $forum_id );405 $active_id = bbp_get_forum_last_active_id( $forum_id );416 $forum_id = bbp_get_forum_id( $forum_id ); 417 $active_id = bbp_get_forum_last_active_id( $forum_id ); 406 418 407 419 if ( empty( $active_id ) ) … … 748 760 * @uses bbp_get_forum_id() To get the forum id 749 761 * @uses get_post_meta() To get the forum's last reply id 762 * @uses bbp_get_forum_last_topic_id() To get the forum's last topic id 750 763 * @uses apply_filters() Calls 'bbp_get_forum_last_reply_id' with 751 764 * the last reply id and forum id … … 1319 1332 * @since bbPress (r2860) 1320 1333 * 1334 * @param array $args Arguments passed to alter output 1321 1335 * @uses bbp_get_single_forum_description() Return the eventual output 1322 *1323 * @param arr $args Arguments passed to alter output1324 1336 */ 1325 1337 function bbp_single_forum_description( $args = '' ) { … … 1327 1339 } 1328 1340 /** 1329 * Return a fancy description of the current forum, including total topics,1330 * to tal replies, and last activity.1341 * Return a fancy description of the current forum, including total 1342 * topics, total replies, and last activity. 1331 1343 * 1332 1344 * @since bbPress (r2860) 1333 1345 * 1334 * @uses wp_parse_args() 1335 * @uses bbp_get_forum_id() 1336 * @uses bbp_get_forum_topic_count() 1337 * @uses bbp_get_forum_reply_count() 1338 * @uses bbp_get_forum_subforum_count() 1339 * @uses bbp_get_forum_freshness_link() 1340 * @uses bbp_get_forum_last_reply_id() 1341 * @uses bbp_get_reply_author_avatar() 1342 * @uses bbp_get_reply_author_link() 1343 * @uses apply_filters() 1344 * 1345 * @param arr $args Arguments passed to alter output 1346 * 1346 * @param mixed $args This function supports these arguments: 1347 * - topic_id: Topic id 1348 * - before: Before the text 1349 * - after: After the text 1350 * - size: Size of the avatar 1351 * @uses bbp_get_forum_id() To get the forum id 1352 * @uses bbp_get_forum_topic_count() To get the forum topic count 1353 * @uses bbp_get_forum_reply_count() To get the forum reply count 1354 * @uses bbp_get_forum_subforum_count() To get the forum subforum count 1355 * @uses bbp_get_forum_freshness_link() To get the forum freshness link 1356 * @uses bbp_get_forum_last_active_id() To get the forum last active id 1357 * @uses bbp_get_author_link() To get the author link 1358 * @uses add_filter() To add the 'view all' filter back 1359 * @uses apply_filters() Calls 'bbp_get_single_forum_description' with 1360 * the description and args 1347 1361 * @return string Filtered forum description 1348 1362 */
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)