Changeset 9833
- Timestamp:
- 05/03/2015 06:51:25 PM (9 years ago)
- Location:
- trunk/src/bp-activity
- Files:
-
- 13 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-activity/bp-activity-actions.php
r9819 r9833 167 167 * 168 168 * @param int $activity_id The activity ID. 169 * @param int $user_id The user associated with the activity.169 * @param int $user_id The user associated with the activity. 170 170 */ 171 171 do_action( 'bp_activity_before_action_delete_activity', $activity_id, $activity->user_id ); … … 183 183 * 184 184 * @param int $activity_id The activity ID. 185 * @param int $user_id The user associated with the activity.185 * @param int $user_id The user associated with the activity. 186 186 */ 187 187 do_action( 'bp_activity_action_delete_activity', $activity_id, $activity->user_id ); … … 201 201 * 202 202 * @param int $activity_id Activity id to be deleted. Defaults to 0. 203 * 203 204 * @return bool False on failure. 204 205 */ … … 235 236 * 236 237 * @param int $activity_id Activity ID to be marked as spam. 237 * @param object $activity Activity object for the ID to be marked as spam.238 * @param object $activity Activity object for the ID to be marked as spam. 238 239 */ 239 240 do_action( 'bp_activity_before_action_spam_activity', $activity->id, $activity ); … … 252 253 * 253 254 * @param int $activity_id Activity ID that was marked as spam. 254 * @param int $user_id User ID associated with activity.255 * @param int $user_id User ID associated with activity. 255 256 */ 256 257 do_action( 'bp_activity_action_spam_activity', $activity_id, $activity->user_id ); … … 299 300 * @since BuddyPress (1.2.0) 300 301 * 301 * @param string $ whats-newActivity message being posted.302 * @param string $value Activity message being posted. 302 303 */ 303 304 $content = apply_filters( 'bp_activity_post_update_content', $_POST['whats-new'] ); … … 310 311 * @since BuddyPress (1.2.0) 311 312 * 312 * @param string $ whats-new-post-objectItem type to associate with.313 * @param string $value Item type to associate with. 313 314 */ 314 315 $object = apply_filters( 'bp_activity_post_update_object', $_POST['whats-new-post-object'] ); … … 322 323 * @since BuddyPress (1.2.0) 323 324 * 324 * @param string $ whats-new-post-inChosen component to post activity to.325 * @param string $value Chosen component to post activity to. 325 326 */ 326 327 $item_id = apply_filters( 'bp_activity_post_update_item_id', $_POST['whats-new-post-in'] ); … … 350 351 * @since BuddyPress (1.2.0) 351 352 * 352 * @param string $object Activity item being associated to.353 * @param string $object Activity item being associated to. 353 354 * @param string $item_id Component ID being posted to. 354 355 * @param string $content Activity content being posted. … … 399 400 * @since BuddyPress (1.2.0) 400 401 * 401 * @param string $ comment_form_idID of the activity being replied to.402 * @param string $value ID of the activity being replied to. 402 403 */ 403 404 $activity_id = apply_filters( 'bp_activity_post_comment_activity_id', $_POST['comment_form_id'] ); … … 408 409 * @since BuddyPress (1.2.0) 409 410 * 410 * @param string $ ac_input_activity_idComment content being posted.411 * @param string $value Comment content being posted. 411 412 */ 412 413 $content = apply_filters( 'bp_activity_post_comment_content', $_POST['ac_input_' . $activity_id] ); … … 729 730 * @since BuddyPress (1.6.0) 730 731 * 731 * @param bool bp_is_akismet_active Return value of bp_is_akismet_active boolean function.732 * @param bool $value Return value of bp_is_akismet_active boolean function. 732 733 */ 733 734 if ( ! apply_filters( 'bp_activity_use_akismet', bp_is_akismet_active() ) ) -
trunk/src/bp-activity/bp-activity-admin.php
r9819 r9833 53 53 * 54 54 * @param array $custom_menus The list of top-level BP menu items. 55 * 55 56 * @return array $custom_menus List of top-level BP menu items, with Activity added 56 57 */ … … 139 140 * @since BuddyPress (1.6.0) 140 141 * 141 * @param string $value Will always be false unless another plugin filters it 142 * first. 143 * @param string $option Screen option name. 142 * @param string $value Will always be false unless another plugin filters it first. 143 * @param string $option Screen option name. 144 144 * @param string $new_value Screen option form value. 145 * 145 146 * @return string Option value. False to abandon update. 146 147 */ … … 162 163 * @since BuddyPress (1.6.0) 163 164 * 165 * @param array $hidden Array of items to hide. 164 166 * @param WP_Screen $screen Screen identifier. 167 * 165 168 * @return array Hidden Meta Boxes. 166 169 */ … … 194 197 * @since BuddyPress (1.6.0) 195 198 * 196 * @global object $bpBuddyPress global settings.199 * @global object $bp BuddyPress global settings. 197 200 * @global BP_Activity_List_Table $bp_activity_list_table Activity screen list table. 198 201 */ … … 412 415 * @since BuddyPress (1.6.0) 413 416 * 414 * @param array Array holding spam, not spam, deleted counts, error IDs.415 * @param string $redirect_to URL to redirect to.417 * @param array $value Array holding spam, not spam, deleted counts, error IDs. 418 * @param string $redirect_to URL to redirect to. 416 419 * @param array $activity_ids Original array of activity IDs. 417 420 */ … … 640 643 * @since BuddyPress (1.6.0) 641 644 * 642 * @param array Array holding single activity object.645 * @param array $value Array holding single activity object that was passed by reference. 643 646 */ 644 647 do_action_ref_array( 'bp_activity_admin_edit', array( &$activity ) ); ?> … … 889 892 * @since BuddyPress (1.6.0) 890 893 * 891 * @global BP_Activity_List_Table $bp_activity_list_table Activity screen list 892 * table. 893 * @global string $plugin_page The current plugin page. 894 * @global BP_Activity_List_Table $bp_activity_list_table Activity screen list table. 895 * @global string $plugin_page The current plugin page. 894 896 */ 895 897 function bp_activity_admin_index() { … … 1289 1291 * 1290 1292 * @param string $url_base Current URL base for view. 1291 * @param string $view Current view being displayed.1293 * @param string $view Current view being displayed. 1292 1294 */ 1293 1295 do_action( 'bp_activity_list_table_get_views', $url_base, $this->view ); ?> … … 1522 1524 * 1523 1525 * @param array $actions Array of available actions user could use. 1524 * @param array $item Current item being added to page.1526 * @param array $item Current item being added to page. 1525 1527 */ 1526 1528 $actions = apply_filters( 'bp_activity_admin_comment_row_actions', array_filter( $actions ), $item ); … … 1574 1576 * @since BuddyPress (1.6.0) 1575 1577 * 1576 * @param array Array of default activity types.1577 * @param array $item Current item being displayed.1578 * @param array $value Array of default activity types. 1579 * @param array $item Current item being displayed. 1578 1580 */ 1579 1581 if ( empty( $item['item_id'] ) || ! in_array( $item['type'], apply_filters( 'bp_activity_admin_root_activity_types', array( 'activity_comment' ), $item ) ) ) { … … 1606 1608 * 1607 1609 * @param int $activity_id Activity ID to retrieve User ID for. 1610 * 1608 1611 * @return int User ID of the activity item in question. 1609 1612 */ … … 1646 1649 * 1647 1650 * @param array $item An array version of the BP_Activity_Activity object. 1651 * 1648 1652 * @return bool 1649 1653 */ … … 1710 1714 * 1711 1715 * @param array $tree Source array. 1716 * 1712 1717 * @return array Flattened array. 1713 1718 */ -
trunk/src/bp-activity/bp-activity-akismet.php
r9819 r9833 72 72 * @since BuddyPress (1.6.0) 73 73 * 74 * @param array $actions The hover links.74 * @param array $actions The hover links. 75 75 * @param array $activity The activity for the current row being processed. 76 * 76 77 * @return array The hover links. 77 78 */ … … 163 164 * @see bp_dtheme_post_update() 164 165 * 165 * @param string $content Activity update text.166 * @param int $user_idUser ID.167 * @param int $activity_id Activity ID.166 * @param string $content Activity update text. 167 * @param int $user_id User ID. 168 * @param int $activity_id Activity ID. 168 169 */ 169 170 public function check_member_activity_update( $content, $user_id, $activity_id ) { … … 263 264 * @since BuddyPress (1.6.0) 264 265 * 265 * @param BP_Activity_Activity $activity 266 * @param string $source Either "by_a_person" (e.g. a person has manually marked the activity as spam) or "by_akismet" (automatically spammed). 266 * @param BP_Activity_Activity $activity Activity item being spammed. 267 * @param string $source Either "by_a_person" (e.g. a person has 268 * manually marked the activity as spam) or 269 * "by_akismet" (automatically spammed). 267 270 */ 268 271 public function mark_as_spam( $activity, $source ) { … … 276 279 * 277 280 * @param BP_Activity_Activity $activity Activity object being marked as spam. 278 * @param string $source Source of the whom marked as spam. Either "by_a_person" (e.g. a person has manually marked the activity as spam) or "by_akismet". 281 * @param string $source Source of the whom marked as spam. 282 * Either "by_a_person" (e.g. a person has 283 * manually marked the activity as spam) 284 * or "by_akismet". 279 285 */ 280 286 do_action( 'bp_activity_akismet_mark_as_spam', $activity, $source ); … … 286 292 * @since BuddyPress (1.6.0) 287 293 * 288 * @param BP_Activity_Activity $activity 289 * @param string $source Either "by_a_person" (e.g. a person has manually marked the activity as ham) or "by_akismet" (automatically hammed). 294 * @param BP_Activity_Activity $activity Activity item being hammed. 295 * @param string $source Either "by_a_person" (e.g. a person has 296 * manually marked the activity as ham) or 297 * "by_akismet" (automatically hammed). 290 298 */ 291 299 public function mark_as_ham( $activity, $source ) { … … 300 308 * 301 309 * @param BP_Activity_Activity $activity Activity object being marked as ham. 302 * @param string $source Source of the whom marked as ham. Either "by_a_person" (e.g. a person has manually marked the activity as ham) or "by_akismet" (automatically hammed). 310 * @param string $source Source of the whom marked as ham. 311 * Either "by_a_person" (e.g. a person has 312 * manually marked the activity as ham) or 313 * "by_akismet" (automatically hammed). 303 314 */ 304 315 do_action( 'bp_activity_akismet_mark_as_ham', $activity, $source ); … … 314 325 * 315 326 * @param BP_Activity_Activity $activity Activity item data. 327 * 328 * @return array 316 329 */ 317 330 public static function build_akismet_data_package( $activity ) { … … 348 361 * @since BuddyPress (1.6.0) 349 362 * 350 * @param array $activity_data Array of activity data for Akismet to inspect.351 * @param BP_Activity_Activity $activity Activity item data.363 * @param array $activity_data Array of activity data for Akismet to inspect. 364 * @param BP_Activity_Activity $activity Activity item data. 352 365 */ 353 366 return apply_filters( 'bp_akismet_build_akismet_data_package', $activity_data, $activity ); … … 392 405 * @since BuddyPress (1.6.0) 393 406 * 394 * @param BP_Activity_Activity $activity The activity item proven to be spam. 395 * @param array $activity_data Array of activity data for item including Akismet check results data. 407 * @param BP_Activity_Activity $activity The activity item proven to be spam. 408 * @param array $activity_data Array of activity data for item including 409 * Akismet check results data. 396 410 */ 397 411 do_action_ref_array( 'bp_activity_akismet_spam_caught', array( &$activity, $activity_data ) ); … … 485 499 * @global string $akismet_api_port 486 500 * 487 * @param array $activity_data Packet of information to submit to Akismet. 488 * @param string $check "check" or "submit". 489 * @param string $spam "spam" or "ham". 501 * @param array $activity_data Packet of information to submit to Akismet. 502 * @param string $check "check" or "submit". 503 * @param string $spam "spam" or "ham". 504 * 490 505 * @return array $activity_data Activity data, with Akismet data added. 491 506 */ … … 562 577 * 563 578 * @param string $user_agent User agent string, as generated by Akismet. 579 * 564 580 * @return string $user_agent Modified user agent string. 565 581 */ … … 611 627 * @since BuddyPress (1.6.0) 612 628 * 613 * @param int $activity_id Activity item ID.614 * @param string $message Human-readable description of what's changed.615 * @param string $event The type of check we were carrying out.629 * @param int $activity_id Activity item ID. 630 * @param string $message Human-readable description of what's changed. 631 * @param string $event The type of check we were carrying out. 616 632 */ 617 633 public function update_activity_history( $activity_id = 0, $message = '', $event = '' ) { … … 633 649 * 634 650 * @param int $activity_id Activity item ID. 651 * 635 652 * @return array The activity item's Akismet history. 636 653 */ -
trunk/src/bp-activity/bp-activity-cache.php
r9819 r9833 17 17 * using querying activitymeta inline. 18 18 * 19 * @param int|str |array$activity_ids Accepts a single activity ID, or a comma-20 * separated list or array of activity ids19 * @param int|string|array|bool $activity_ids Accepts a single activity ID, or a comma- 20 * separated list or array of activity ids 21 21 */ 22 22 function bp_activity_update_meta_cache( $activity_ids = false ) { -
trunk/src/bp-activity/bp-activity-filters.php
r9819 r9833 180 180 * 181 181 * @param string $content The activity content. 182 * 182 183 * @return string $content Filtered activity content. 183 184 */ … … 221 222 * @since BuddyPress (1.2.0) 222 223 * 223 * @param string $content The contents of a given item. 224 * @param int $activity_id The activity id. Deprecated. 224 * @param string $content The contents of a given item. 225 * @param int $activity_id The activity id. Deprecated. 226 * 225 227 * @return string $content Content filtered for mentions. 226 228 */ … … 339 341 // Send @mentions and setup BP notifications 340 342 foreach( (array) $usernames as $user_id => $username ) { 343 341 344 /** 342 345 * Filters BuddyPress' ability to send email notifications for @mentions. … … 344 347 * @since BuddyPress (1.6.0) 345 348 * 346 * @param bool Whether or not BuddyPress should send a notification to the mentioned users.349 * @param bool $value Whether or not BuddyPress should send a notification to the mentioned users. 347 350 * @param array $usernames Array of users potentially notified. 348 351 */ … … 362 365 * 363 366 * @param string $text Activity text. 367 * 364 368 * @return string $text Text with rel=nofollow added to any links. 365 369 */ … … 373 377 * @since BuddyPress (1.2.0) 374 378 * 375 * @param array $matches376 *377 379 * @param array $matches Items matched by preg_replace_callback() in bp_activity_make_nofollow_filter(). 380 * 378 381 * @return string $text Link with rel=nofollow added 379 382 */ … … 400 403 * 401 404 * @param string $text The original activity entry text. 405 * 402 406 * @return string $excerpt The truncated text. 403 407 */ … … 408 412 * Provides a filter that lets you choose whether to skip this filter on a per-activity basis. 409 413 * 410 * @param bool $maybe_truncate_text If true, text should be checked to see if it needs truncating.411 414 * @since BuddyPress (2.3.0) 415 * 416 * @param bool $value If true, text should be checked to see if it needs truncating. 412 417 */ 413 418 $maybe_truncate_text = apply_filters( … … 457 462 * @since BuddyPress (1.5.0) 458 463 * 459 * @param string $excerpt Excerpt text and markup to be displayed.460 * @param string $text The original activity entry text.464 * @param string $excerpt Excerpt text and markup to be displayed. 465 * @param string $text The original activity entry text. 461 466 * @param string $append_text The final append text applied. 462 467 */ … … 472 477 * 473 478 * @param array $js_handles The original dependencies. 479 * 474 480 * @return array $js_handles The new dependencies. 475 481 */ … … 492 498 * 493 499 * @param string $classes 500 * 494 501 * @return string $classes 495 502 */ … … 511 518 * 512 519 * @param string $classes 520 * 513 521 * @return string $classes 514 522 */ … … 540 548 * @param array $response 541 549 * @param array $data 550 * 542 551 * @return array $response 543 552 */ … … 601 610 * 602 611 * @param array $strings Localized strings. 612 * 603 613 * @return array $strings 604 614 */ … … 661 671 * @since BuddyPress (2.2.0) 662 672 * 663 * @param array $retval Empty array by default 664 * @param array $filter Current activity arguments 673 * @param array $retval Empty array by default. 674 * @param array $filter Current activity arguments. 675 * 665 676 * @return array 666 677 */ … … 710 721 * @since BuddyPress (2.2.0) 711 722 * 712 * @param array $retval Empty array by default 713 * @param array $filter Current activity arguments 723 * @param array $retval Empty array by default. 724 * @param array $filter Current activity arguments. 725 * 714 726 * @return array 715 727 */ … … 767 779 * @since BuddyPress (2.2.0) 768 780 * 769 * @param array $retval Empty array by default 770 * @param array $filter Current activity arguments 781 * @param array $retval Empty array by default. 782 * @param array $filter Current activity arguments. 783 * 771 784 * @return array 772 785 */ -
trunk/src/bp-activity/bp-activity-functions.php
r9819 r9833 61 61 * mentions suggestions? 62 62 * 63 * @since BuddyPress (2.1.0) 64 * 63 65 * @return bool True if mentions scripts should be loaded. 64 * @since BuddyPress (2.1.0)65 66 */ 66 67 function bp_activity_maybe_load_mentions_scripts() { … … 73 74 * @since BuddyPress (2.1.0) 74 75 * 75 * @param bool $load_mentions True to load mentions assets, false otherwise.76 * @param bool $load_mentions True to load mentions assets, false otherwise. 76 77 * @param bool $mentions_enabled True if mentions are enabled. 77 78 */ … … 85 86 * 86 87 * @param string $content The content of the activity, usually found in 87 * $activity->content. 88 * $activity->content. 89 * 88 90 * @return array|bool Associative array with user ID as key and username as 89 * value. Boolean false if no mentions found.91 * value. Boolean false if no mentions found. 90 92 */ 91 93 function bp_activity_find_mentions( $content ) { … … 148 150 * @uses bp_activity_update_mention_count_for_user() 149 151 * 150 * @param int $activity_id The unique id for the activity item. 151 * @param string $action Can be 'delete' or 'add'. Defaults to 'add'. 152 * @param int $activity_id The unique id for the activity item. 153 * @param string $action Can be 'delete' or 'add'. Defaults to 'add'. 154 * 155 * @return bool 152 156 */ 153 157 function bp_activity_adjust_mention_count( $activity_id = 0, $action = 'add' ) { … … 186 190 * @uses bp_update_user_meta() 187 191 * 188 * @param int $user_id The user ID. 189 * @param int $activity_id The unique ID for the activity item. 190 * @param string $action 'delete' or 'add'. Default: 'add'. 192 * @param int $user_id The user ID. 193 * @param int $activity_id The unique ID for the activity item. 194 * @param string $action 'delete' or 'add'. Default: 'add'. 195 * 191 196 * @return bool 192 197 */ … … 239 244 * 240 245 * @since BuddyPress (1.9.0) 246 * 247 * @param int|string $user_id ID of the user to get @-mention name for. 241 248 * 242 249 * @return string User name appropriate for @-mentions. … … 316 323 * @since BuddyPress (1.1.0) 317 324 * 318 * @param string $component_id The unique string ID of the component. 319 * @param string $type The action type. 320 * @param string $description The action description. 321 * @param callable $format_callback Callback for formatting the action string. 322 * @param string $label String to describe this action in the activity stream filter dropdown. 323 * @param array $context Optional. Activity stream contexts where the filter should appear. 324 * Values: 'activity', 'member', 'member_groups', 'group' 325 * @param int $position Optional. The position of the action when listed in dropdowns. 325 * @param string $component_id The unique string ID of the component. 326 * @param string $type The action type. 327 * @param string $description The action description. 328 * @param callable|bool $format_callback Callback for formatting the action string. 329 * @param string|bool $label String to describe this action in the activity stream filter dropdown. 330 * @param array $context Optional. Activity stream contexts where the filter should appear. 331 * Values: 'activity', 'member', 'member_groups', 'group' 332 * @param int $position Optional. The position of the action when listed in dropdowns. 333 * 326 334 * @return bool False if any param is empty, otherwise true. 327 335 */ … … 353 361 * @since BuddyPress (1.1.0) 354 362 * 355 * @param array $array Array of arguments for action type being set.356 * @param string $component_id ID of the current component being set.357 * @param string $type Action type being set.358 * @param string $description Action description for action being set.363 * @param array $array Array of arguments for action type being set. 364 * @param string $component_id ID of the current component being set. 365 * @param string $type Action type being set. 366 * @param string $description Action description for action being set. 359 367 * @param callable $format_callback Callback for formatting the action string. 360 * @param string $label String to describe this action in the activity stream filter dropdown.361 * @param array $context Activity stream contexts where the filter should appear. 'activity', 'member',362 * 'member_groups', 'group'.368 * @param string $label String to describe this action in the activity stream filter dropdown. 369 * @param array $context Activity stream contexts where the filter should appear. 'activity', 'member', 370 * 'member_groups', 'group'. 363 371 */ 364 372 $bp->activity->actions->{$component_id}->{$type} = apply_filters( 'bp_activity_set_action', array( … … 406 414 * the post type does not natively support comments, otherwise false. 407 415 * } 416 * 417 * @return bool 408 418 */ 409 419 function bp_activity_set_post_type_tracking_args( $post_type = '', $args = array() ) { … … 433 443 * @since BuddyPress (2.2.0) 434 444 * 435 * @param string $post_type Name of the post type 445 * @param string $post_type Name of the post type. 446 * 436 447 * @return object The tracking arguments of the post type. 437 448 */ … … 490 501 * 491 502 * @param object $post_type_activity The tracking arguments of the post type. 492 * @param string $post_type Name of the post type.503 * @param string $post_type Name of the post type. 493 504 */ 494 505 return apply_filters( 'bp_activity_get_post_type_tracking_args', $post_type_activity, $post_type ); … … 582 593 * 583 594 * @param string $component_id The unique string ID of the component. 584 * @param string $key The action key. 595 * @param string $key The action key. 596 * 585 597 * @return string|bool Action value if found, otherwise false. 586 598 */ … … 654 666 * 655 667 * @param int $user_id ID of the user whose favorites are being queried. 668 * 656 669 * @return array IDs of the user's favorite activity items. 657 670 */ … … 690 703 * 691 704 * @param int $activity_id ID of the activity item being favorited. 692 * @param int $user_id ID of the user favoriting the activity item. 705 * @param int $user_id ID of the user favoriting the activity item. 706 * 693 707 * @return bool True on success, false on failure. 694 708 */ … … 734 748 * 735 749 * @param int $activity_id ID of the activity item being favorited. 736 * @param int $user_id ID of the user doing the favoriting.750 * @param int $user_id ID of the user doing the favoriting. 737 751 */ 738 752 do_action( 'bp_activity_add_user_favorite', $activity_id, $user_id ); … … 750 764 * 751 765 * @param int $activity_id ID of the activity item being favorited. 752 * @param int $user_id ID of the user doing the favoriting.766 * @param int $user_id ID of the user doing the favoriting. 753 767 */ 754 768 do_action( 'bp_activity_add_user_favorite_fail', $activity_id, $user_id ); … … 771 785 * 772 786 * @param int $activity_id ID of the activity item being unfavorited. 773 * @param int $user_id ID of the user unfavoriting the activity item. 787 * @param int $user_id ID of the user unfavoriting the activity item. 788 * 774 789 * @return bool True on success, false on failure. 775 790 */ … … 814 829 * 815 830 * @param int $activity_id ID of the activity item being unfavorited. 816 * @param int $user_id ID of the user doing the unfavoriting.831 * @param int $user_id ID of the user doing the unfavoriting. 817 832 */ 818 833 do_action( 'bp_activity_remove_user_favorite', $activity_id, $user_id ); … … 846 861 * 847 862 * @param string $content The content to filter by. 863 * 848 864 * @return int|null The ID of the located activity item. Null if none is found. 849 865 */ … … 890 906 * 891 907 * @param int $user_id ID of the user whose favorite count is being requested. 908 * 892 909 * @return int Total favorite count for the user. 893 910 */ … … 911 928 * @global object $wpdb WordPress database access object. 912 929 * 913 * @param int $activity_id ID of the activity item whose metadata is being deleted. 914 * @param string $meta_key Optional. The key of the metadata being deleted. If 915 * omitted, all metadata associated with the activity 916 * item will be deleted. 917 * @param string $meta_value Optional. If present, the metadata will only be 918 * deleted if the meta_value matches this parameter. 919 * @param bool $delete_all Optional. If true, delete matching metadata entries 920 * for all objects, ignoring the specified object_id. Otherwise, 921 * only delete matching metadata entries for the specified 922 * activity item. Default: false. 930 * @param int $activity_id ID of the activity item whose metadata is being deleted. 931 * @param string $meta_key Optional. The key of the metadata being deleted. If 932 * omitted, all metadata associated with the activity 933 * item will be deleted. 934 * @param string $meta_value Optional. If present, the metadata will only be 935 * deleted if the meta_value matches this parameter. 936 * @param bool $delete_all Optional. If true, delete matching metadata entries 937 * for all objects, ignoring the specified object_id. Otherwise, 938 * only delete matching metadata entries for the specified 939 * activity item. Default: false. 940 * 923 941 * @return bool True on success, false on failure. 924 942 */ … … 954 972 * @uses apply_filters() To call the 'bp_activity_get_meta' hook. 955 973 * 956 * @param int $activity_id ID of the activity item whose metadata is being requested. 957 * @param string $meta_key Optional. If present, only the metadata matching 958 * that meta key will be returned. Otherwise, all metadata for the 959 * activity item will be fetched. 960 * @param bool $single Optional. If true, return only the first value of the 961 * specified meta_key. This parameter has no effect if meta_key is not 962 * specified. Default: true. 974 * @param int $activity_id ID of the activity item whose metadata is being requested. 975 * @param string $meta_key Optional. If present, only the metadata matching 976 * that meta key will be returned. Otherwise, all metadata for the 977 * activity item will be fetched. 978 * @param bool $single Optional. If true, return only the first value of the 979 * specified meta_key. This parameter has no effect if meta_key is not 980 * specified. Default: true. 981 * 963 982 * @return mixed The meta value(s) being requested. 964 983 */ … … 973 992 * @since BuddyPress (1.5.0) 974 993 * 975 * @param mixed $retval The meta values for the activity item.994 * @param mixed $retval The meta values for the activity item. 976 995 * @param int $activity_id ID of the activity item. 977 * @param string $meta_key Meta key for the value being requested.978 * @param bool $single Whether to return one matched meta key row or all.996 * @param string $meta_key Meta key for the value being requested. 997 * @param bool $single Whether to return one matched meta key row or all. 979 998 */ 980 999 return apply_filters( 'bp_activity_get_meta', $retval, $activity_id, $meta_key, $single ); … … 986 1005 * @since BuddyPress (1.2.0) 987 1006 * 988 * @param int $activity_id ID of the activity item whose metadata is being 989 * updated. 990 * @param string $meta_key Key of the metadata being updated. 991 * @param mixed $meta_value Value to be set. 992 * @param mixed $prev_value Optional. If specified, only update existing 993 * metadata entries with the specified value. Otherwise, update all 994 * entries. 1007 * @param int $activity_id ID of the activity item whose metadata is being updated. 1008 * @param string $meta_key Key of the metadata being updated. 1009 * @param mixed $meta_value Value to be set. 1010 * @param mixed $prev_value Optional. If specified, only update existing metadata entries 1011 * with the specified value. Otherwise, update all entries. 1012 * 995 1013 * @return bool|int Returns false on failure. On successful update of existing 996 * metadata, returns true. On successful creation of new metadata,997 * returns the integer ID of the new metadata row.1014 * metadata, returns true. On successful creation of new metadata, 1015 * returns the integer ID of the new metadata row. 998 1016 */ 999 1017 function bp_activity_update_meta( $activity_id, $meta_key, $meta_value, $prev_value = '' ) { … … 1010 1028 * @since BuddyPress (2.0.0) 1011 1029 * 1012 * @param int $activity_id ID of the activity item. 1013 * @param string $meta_key Metadata key. 1014 * @param mixed $meta_value Metadata value. 1015 * @param bool $unique Optional. Whether to enforce a single metadata value 1016 * for the given key. If true, and the object already has a value for 1017 * the key, no change will be made. Default: false. 1030 * @param int $activity_id ID of the activity item. 1031 * @param string $meta_key Metadata key. 1032 * @param mixed $meta_value Metadata value. 1033 * @param bool $unique Optional. Whether to enforce a single metadata value for the 1034 * given key. If true, and the object already has a value for 1035 * the key, no change will be made. Default: false. 1036 * 1018 1037 * @return int|bool The meta ID on successful update, false on failure. 1019 1038 */ … … 1040 1059 * 1041 1060 * @param int $user_id ID of the user whose activity is being deleted. 1061 * 1062 * @return bool 1042 1063 */ 1043 1064 function bp_activity_remove_all_user_data( $user_id = 0 ) { … … 1078 1099 * 1079 1100 * @param int $user_id ID of the user whose activity is being spammed. 1101 * 1102 * @return bool 1080 1103 */ 1081 1104 function bp_activity_spam_all_user_data( $user_id = 0 ) { … … 1131 1154 * @since BuddyPress (1.6.0) 1132 1155 * 1133 * @param int $user_id ID of the user whose activity is being marked as spam.1156 * @param int $user_id ID of the user whose activity is being marked as spam. 1134 1157 * @param array $activities Array of activity items being marked as spam. 1135 1158 */ … … 1146 1169 * 1147 1170 * @param int $user_id ID of the user whose activity is being hammed. 1171 * 1172 * @return bool 1148 1173 */ 1149 1174 function bp_activity_ham_all_user_data( $user_id = 0 ) { … … 1200 1225 * @since BuddyPress (1.6.0) 1201 1226 * 1202 * @param int $user_id ID of the user whose activity is being marked as ham.1227 * @param int $user_id ID of the user whose activity is being marked as ham. 1203 1228 * @param array $activities Array of activity items being marked as ham. 1204 1229 */ … … 1250 1275 * 1251 1276 * @param object $activity Activity data object. 1277 * 1252 1278 * @return string|bool Returns false if no callback is found, otherwise returns 1253 * the formatted action string.1279 * the formatted action string. 1254 1280 */ 1255 1281 function bp_activity_generate_action_string( $activity ) { … … 1274 1300 * @since BuddyPress (2.0.0) 1275 1301 * 1276 * @param BP_Activity_Activity $action Action string being requested.1302 * @param BP_Activity_Activity $action Action string being requested. 1277 1303 * @param BP_Activity_Activity $activity Activity item object. 1278 1304 */ … … 1290 1316 * @since BuddyPress (2.0.0) 1291 1317 * 1292 * @param string $action Static activity action.1318 * @param string $action Static activity action. 1293 1319 * @param object $activity Activity data object. 1320 * 1294 1321 * @return string 1295 1322 */ … … 1302 1329 * @since BuddyPress (1.2.0) 1303 1330 * 1304 * @param string $action Activity action string value.1331 * @param string $action Activity action string value. 1305 1332 * @param BP_Activity_Activity $activity Activity item object. 1306 1333 */ … … 1313 1340 * @since BuddyPress (2.0.0) 1314 1341 * 1315 * @param string $action Static activity action.1342 * @param string $action Static activity action. 1316 1343 * @param object $activity Activity data object. 1344 * 1317 1345 * @return string 1318 1346 */ … … 1325 1353 * @since BuddyPress (1.2.0) 1326 1354 * 1327 * @param string $action Activity action string value.1355 * @param string $action Activity action string value. 1328 1356 * @param BP_Activity_Activity $activity Activity item object. 1329 1357 */ … … 1338 1366 * @param string $action Static activity action. 1339 1367 * @param object $activity Activity data object. 1368 * 1340 1369 * @return string 1341 1370 */ … … 1382 1411 * @since BuddyPress (2.2.0) 1383 1412 * 1384 * @param string $action Activity action string value.1413 * @param string $action Activity action string value. 1385 1414 * @param BP_Activity_Activity $activity Activity item object. 1386 1415 */ … … 1414 1443 * @uses apply_filters_ref_array() To call the 'bp_activity_get' hook. 1415 1444 * 1416 * @param array $args See BP_Activity_Activity::get() for description. 1445 * @param array|string $args See BP_Activity_Activity::get() for description. 1446 * 1417 1447 * @return array $activity See BP_Activity_Activity::get() for description. 1418 1448 */ … … 1505 1535 * 1506 1536 * @param BP_Activity_Activity $activity Requested activity object. 1507 * @param array $r Arguments used for the activity query.1537 * @param array $r Arguments used for the activity query. 1508 1538 */ 1509 1539 return apply_filters_ref_array( 'bp_activity_get', array( &$activity, &$r ) ); … … 1520 1550 * @uses BP_Activity_Activity::get() {@link BP_Activity_Activity} 1521 1551 * 1522 * @param array $args {1552 * @param array|string $args { 1523 1553 * All arguments and defaults are shared with BP_Activity_Activity::get(), 1524 1554 * except for the following: … … 1560 1590 * 1561 1591 * @param BP_Activity_Activity $activity Requested activity object. 1562 * @param array $args Original passed in arguments.1592 * @param array $args Original passed in arguments. 1563 1593 * @param array $get_args Constructed arguments used with request. 1564 1594 */ … … 1577 1607 * @uses do_action() To call the 'bp_activity_add' hook 1578 1608 * 1579 * @param array $args {1609 * @param array|string $args { 1580 1610 * An array of arguments. 1581 * @type int|bool $id Pass an activity ID to update an existing item, or1582 * false to create a new item. Default: false.1583 * @type string $actionOptional. The activity action/description, typically1584 * something like "Joe posted an update". Values passed to this param1585 * will be stored in the database and used as a fallback for when the1586 * activity item's format_callback cannot be found (eg, when the1587 * component is disabled). As long as you have registered a1588 * format_callback for your $type, it is unnecessary to include this1589 * argument - BP will generate it automatically.1590 * See {@link bp_activity_set_action()}.1591 * @type string $contentOptional. The content of the activity item.1592 * @type string $componentThe unique name of the component associated with1593 * the activity item - 'groups', 'profile', etc.1594 * @type string $typeThe specific activity type, used for directory1595 * filtering. 'new_blog_post', 'activity_update', etc.1596 * @type string $primary_linkOptional. The URL for this item, as used in1597 * RSS feeds. Defaults to the URL for this activity item's permalink page.1598 * @type int|bool $user_id Optional. The ID of the user associated with the1599 * activity item. May be set to false or 0 if the item is not related1600 * to any user. Default: the ID of the currently logged-in user.1601 * @type int $item_id Optional. The ID of the associated item.1602 * @type int $secondary_item_id Optional. The ID of a secondary associated1603 * 1604 * @type string $date_recorded Optional. The GMT time, in Y-m-d h:i:s format,1605 * whenthe item was recorded. Defaults to the current time.1606 * @type bool $hide_sitewideShould the item be hidden on sitewide streams?1607 * Default: false.1608 * @type bool $is_spamShould the item be marked as spam? Default: false.1611 * @type int|bool $id Pass an activity ID to update an existing item, or 1612 * false to create a new item. Default: false. 1613 * @type string $action Optional. The activity action/description, typically 1614 * something like "Joe posted an update". Values passed to this param 1615 * will be stored in the database and used as a fallback for when the 1616 * activity item's format_callback cannot be found (eg, when the 1617 * component is disabled). As long as you have registered a 1618 * format_callback for your $type, it is unnecessary to include this 1619 * argument - BP will generate it automatically. 1620 * See {@link bp_activity_set_action()}. 1621 * @type string $content Optional. The content of the activity item. 1622 * @type string $component The unique name of the component associated with 1623 * the activity item - 'groups', 'profile', etc. 1624 * @type string $type The specific activity type, used for directory 1625 * filtering. 'new_blog_post', 'activity_update', etc. 1626 * @type string $primary_link Optional. The URL for this item, as used in 1627 * RSS feeds. Defaults to the URL for this activity 1628 * item's permalink page. 1629 * @type int|bool $user_id Optional. The ID of the user associated with the activity 1630 * item. May be set to false or 0 if the item is not related 1631 * to any user. Default: the ID of the currently logged-in user. 1632 * @type int $item_id Optional. The ID of the associated item. 1633 * @type int $secondary_item_id Optional. The ID of a secondary associated item. 1634 * @type string $date_recorded Optional. The GMT time, in Y-m-d h:i:s format, when 1635 * the item was recorded. Defaults to the current time. 1636 * @type bool $hide_sitewide Should the item be hidden on sitewide streams? 1637 * Default: false. 1638 * @type bool $is_spam Should the item be marked as spam? Default: false. 1609 1639 * } 1610 1640 * @return int|bool The ID of the activity on success. False on error. … … 1694 1724 * @uses do_action() To call the 'bp_activity_posted_update' hook. 1695 1725 * 1696 * @param array $args {1726 * @param array|string $args { 1697 1727 * @type string $content The content of the activity update. 1698 * @type int $user_id Optional. Defaults to the logged-in user.1728 * @type int $user_id Optional. Defaults to the logged-in user. 1699 1729 * } 1700 1730 * @return int $activity_id The activity id … … 1751 1781 * @since BuddyPress (1.6.0) 1752 1782 * 1753 * @param string $r Content of the activity update.1783 * @param string $r Content of the activity update. 1754 1784 * @param string $activity_content Content of the activity update. 1755 1785 */ … … 1767 1797 * @since BuddyPress (1.2.0) 1768 1798 * 1769 * @param string $content Content of the activity post update.1770 * @param int $user_id ID of the user posting the activity update.1799 * @param string $content Content of the activity post update. 1800 * @param int $user_id ID of the user posting the activity update. 1771 1801 * @param int $activity_id ID of the activity item being updated. 1772 1802 */ … … 1784 1814 * @param WP_Post $post Post object. 1785 1815 * @param int $user_id ID of the post author. 1816 * 1786 1817 * @return int|bool The ID of the activity on success. False on error. 1787 1818 */ … … 1919 1950 * 1920 1951 * @param WP_Post $post Post item. 1952 * 1921 1953 * @return bool True on success, false on failure. 1922 1954 */ … … 1973 2005 * @since BuddyPress (2.2.0) 1974 2006 * 1975 * @param WP_Post $post Post object.2007 * @param WP_Post $post Post object. 1976 2008 * @param BP_Activity_Activity $activity Activity object. 1977 2009 */ … … 1988 2020 * @param int $post_id ID of the post being unpublished. 1989 2021 * @param WP_Post $post Post object. 2022 * 1990 2023 * @return bool True on success, false on failure. 1991 2024 */ … … 2024 2057 * @param array $delete_activity_args Array of arguments for activity deletion. 2025 2058 * @param WP_Post $post Post object. 2026 * @param bool $activity Whether or not the activity 2027 * was successfully deleted. 2059 * @param bool $activity Whether or not the activity was successfully deleted. 2028 2060 */ 2029 2061 do_action( 'bp_activity_post_type_unpublished', $delete_activity_args, $post, $deleted ); … … 2044 2076 * @uses do_action() To call the 'bp_activity_comment_posted' hook. 2045 2077 * 2046 * @param array $args {2047 * @type int $idOptional. Pass an ID to update an existing comment.2048 * @type string $content The content of the comment.2049 * @type int $user_idOptional. The ID of the user making the comment.2050 * Defaults to the ID of the logged-in user.2051 * @type int $activity_id The ID of the "root" activity item, ie the oldest2052 * ancestor of the comment.2053 * @type int $parent_id Optional. The ID of the parent activity item, ie the2054 * item towhich the comment is an immediate reply. If not provided,2055 * this value defaults to the $activity_id.2078 * @param array|string $args { 2079 * @type int $id Optional. Pass an ID to update an existing comment. 2080 * @type string $content The content of the comment. 2081 * @type int $user_id Optional. The ID of the user making the comment. 2082 * Defaults to the ID of the logged-in user. 2083 * @type int $activity_id The ID of the "root" activity item, ie the oldest 2084 * ancestor of the comment. 2085 * @type int $parent_id Optional. The ID of the parent activity item, ie the item to 2086 * which the comment is an immediate reply. If not provided, 2087 * this value defaults to the $activity_id. 2056 2088 * } 2057 2089 * @return int|bool The ID of the comment on success, otherwise false. … … 2142 2174 * 2143 2175 * @param int $comment_id ID of the newly posted activity comment. 2144 * @param array $r Array of parsed comment arguments.2145 * @param int $activity ID of the activity item being commented on.2176 * @param array $r Array of parsed comment arguments. 2177 * @param int $activity ID of the activity item being commented on. 2146 2178 */ 2147 2179 do_action( 'bp_activity_comment_posted', $comment_id, $r, $activity ); … … 2165 2197 * @uses BP_Activity_Activity::save() {@link BP_Activity_Activity} 2166 2198 * 2167 * @param array $args See BP_Activity_Activity::get() for description. 2199 * @param array|string $args See BP_Activity_Activity::get() for description. 2200 * 2168 2201 * @return int $activity_id The ID of the activity item found. 2169 2202 */ … … 2186 2219 * @since BuddyPress (1.2.0) 2187 2220 * 2188 * @param BP_Activity_Activity ID returned by BP_Activity_Activity get_id() method with provided arguments.2221 * @param BP_Activity_Activity $value ID returned by BP_Activity_Activity get_id() method with provided arguments. 2189 2222 */ 2190 2223 return apply_filters( 'bp_activity_get_activity_id', BP_Activity_Activity::get_id( … … 2226 2259 * @uses wp_cache_delete() 2227 2260 * 2228 * @param array $args To delete specific activity items, use 2229 * $args = array( 'id' => $ids ); 2230 * Otherwise, to use filters for item deletion, the argument format is 2231 * the same as BP_Activity_Activity::get(). See that method for a description. 2261 * @param array|string $args To delete specific activity items, use 2262 * $args = array( 'id' => $ids ); Otherwise, to use 2263 * filters for item deletion, the argument format is 2264 * the same as BP_Activity_Activity::get(). 2265 * See that method for a description. 2266 * 2232 2267 * @return bool True on success, false on failure. 2233 2268 */ … … 2312 2347 * @uses bp_activity_delete() 2313 2348 * 2314 * @param array $args See BP_Activity_Activity::get for a description2315 * of accepted arguments.2349 * @param array|string $args See BP_Activity_Activity::get for a 2350 * description of accepted arguments. 2316 2351 * 2317 2352 * @return bool True on success, false on failure. … … 2337 2372 * @uses bp_activity_delete() 2338 2373 * 2339 * @param int ID of the activity item to be deleted. 2374 * @param int $activity_id ID of the activity item to be deleted. 2375 * 2340 2376 * @return bool True on success, false on failure. 2341 2377 */ … … 2354 2390 * @uses bp_activity_delete() 2355 2391 * 2356 * @param int $user_idThe user id.2357 * @param string $content The activity id.2392 * @param int $user_id The user id. 2393 * @param string $content The activity id. 2358 2394 * @param string $component The activity component. 2359 * @param string $type The activity type. 2395 * @param string $type The activity type. 2396 * 2360 2397 * @return bool True on success, false on failure. 2361 2398 */ … … 2379 2416 * @uses bp_activity_delete() 2380 2417 * 2381 * @param int $user_idThe user id.2418 * @param int $user_id The user id. 2382 2419 * @param string $component The activity component. 2420 * 2383 2421 * @return bool True on success, false on failure. 2384 2422 */ … … 2407 2445 * @param int $activity_id The ID of the "root" activity, ie the comment's 2408 2446 * oldest ancestor. 2409 * @param int $comment_id The ID of the comment to be deleted. 2447 * @param int $comment_id The ID of the comment to be deleted. 2448 * 2410 2449 * @return bool True on success, false on failure 2411 2450 */ … … 2420 2459 * @since BuddyPress (1.2.0) 2421 2460 * 2422 * @param bool $value Whether BuddyPress should continue or not.2461 * @param bool $value Whether BuddyPress should continue or not. 2423 2462 * @param int $activity_id ID of the root activity item being deleted. 2424 * @param int $comment_id ID of the comment being deleted.2463 * @param int $comment_id ID of the comment being deleted. 2425 2464 */ 2426 2465 if ( ! apply_filters( 'bp_activity_delete_comment_pre', true, $activity_id, $comment_id ) ) { … … 2448 2487 * 2449 2488 * @param int $activity_id ID of the activity that has had a comment deleted from. 2450 * @param int $comment_id ID of the comment that was deleted.2489 * @param int $comment_id ID of the comment that was deleted. 2451 2490 */ 2452 2491 do_action( 'bp_activity_delete_comment', $activity_id, $comment_id ); … … 2465 2504 * 2466 2505 * @param int $activity_id The ID of the "root" activity, ie the 2467 * comment's oldest ancestor.2468 * @param int $comment_id The ID of the comment to be deleted.2506 * comment's oldest ancestor. 2507 * @param int $comment_id The ID of the comment to be deleted. 2469 2508 */ 2470 2509 function bp_activity_delete_children( $activity_id, $comment_id ) { … … 2502 2541 * @uses apply_filters_ref_array() To call the 'bp_activity_get_permalink' hook. 2503 2542 * 2504 * @param int $activity_id The unique id of the activity object. 2505 * @param object $activity_obj Optional. The activity object. 2543 * @param int $activity_id The unique id of the activity object. 2544 * @param object|bool $activity_obj Optional. The activity object. 2545 * 2506 2546 * @return string $link Permalink for the activity item. 2507 2547 */ … … 2556 2596 * 2557 2597 * @param int $user_id The ID of the user whose activity is being hidden. 2598 * 2558 2599 * @return bool True on success, false on failure. 2559 2600 */ … … 2579 2620 * @uses apply_filters() To call the 'bp_activity_thumbnail_content_images' hook 2580 2621 * 2581 * @param string $content The content of the activity item. 2582 * @param string $link Optional. The unescaped URL that the image should link 2583 * to. If absent, the image will not be a link. 2584 * @param array $args Optional. The args passed to the activity 2585 * creation function (eg bp_blogs_record_activity()). 2622 * @param string $content The content of the activity item. 2623 * @param string|bool $link Optional. The unescaped URL that the image should link 2624 * to. If absent, the image will not be a link. 2625 * @param array|bool $args Optional. The args passed to the activity 2626 * creation function (eg bp_blogs_record_activity()). 2627 * 2586 2628 * @return string $content The content with images stripped and replaced with a 2587 2629 * single thumb. … … 2639 2681 * @param string $content Activity content that had images replaced in. 2640 2682 * @param array $matches Array of all image tags found in the posted content. 2641 * @param array $args Arguments passed into function creating the activity update.2683 * @param array $args Arguments passed into function creating the activity update. 2642 2684 */ 2643 2685 return apply_filters( 'bp_activity_thumbnail_content_images', $content, $matches, $args ); … … 2656 2698 * @param array $activity The data passed to bp_activity_add() or the values 2657 2699 * from an Activity obj. 2700 * 2658 2701 * @return string 2659 2702 */ … … 2668 2711 } 2669 2712 2670 2671 2713 /** 2672 2714 * Filter the class name of the media extractor when creating an Activity summary. … … 2674 2716 * Use this filter to change the media extractor used to extract media info for the activity item. 2675 2717 * 2718 * @since BuddyPress (2.3.0) 2719 * 2676 2720 * @param string $extractor Class name. 2677 * @param string $content The content of the activity item. 2678 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj. 2679 * @since BuddyPress (2.3.0) 2721 * @param string $content The content of the activity item. 2722 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj. 2680 2723 */ 2681 2724 $extractor = apply_filters( 'bp_activity_create_summary_extractor_class', 'BP_Media_Extractor', $content, $activity ); … … 2685 2728 * Filter the arguments passed to the media extractor when creating an Activity summary. 2686 2729 * 2687 * @param array $args Array of bespoke data for the media extractor. 2688 * @param string $content The content of the activity item. 2689 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj. 2730 * @since BuddyPress (2.3.0) 2731 * 2732 * @param array $args Array of bespoke data for the media extractor. 2733 * @param string $content The content of the activity item. 2734 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj. 2690 2735 * @param BP_Media_Extractor $extractor The media extractor object. 2691 * @since BuddyPress (2.3.0)2692 2736 */ 2693 2737 $args = apply_filters( 'bp_activity_create_summary_extractor_args', $args, $content, $activity, $extractor ); … … 2735 2779 $use_media_type = 'images'; 2736 2780 $image_source = 'html'; 2737 2781 2738 2782 // Featured Image > Galleries > inline <img>. 2739 2783 if ( $has_feat_image ) { … … 2757 2801 * Filter the results of the media extractor when creating an Activity summary. 2758 2802 * 2759 * @param array $extracted_media Extracted media item. See {@link BP_Media_Extractor::extract()} for format.2760 * @param string $content Content of the activity item.2761 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj.2762 * @param array $media All results from the media extraction. See {@link BP_Media_Extractor::extract()} for format.2763 * @param string $use_media_type The kind of media item that was preferentially extracted.2764 * @param string $image_source If $use_media_type was "images", the preferential source of the image.2765 * Otherwise empty.2766 2803 * @since BuddyPress (2.3.0) 2804 * 2805 * @param array $extracted_media Extracted media item. See {@link BP_Media_Extractor::extract()} for format. 2806 * @param string $content Content of the activity item. 2807 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj. 2808 * @param array $media All results from the media extraction. 2809 * See {@link BP_Media_Extractor::extract()} for format. 2810 * @param string $use_media_type The kind of media item that was preferentially extracted. 2811 * @param string $image_source If $use_media_type was "images", the preferential source of the image. 2812 * Otherwise empty. 2767 2813 */ 2768 2814 $extracted_media = apply_filters( … … 2792 2838 * Filters the newly-generated summary for the activity item. 2793 2839 * 2794 * @param string $summary Activity summary HTML.2795 * @param string $content $content Content of the activity item.2796 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj.2797 * @param array $extracted_media Media item extracted. See {@link BP_Media_Extractor::extract()} for format.2798 2840 * @since BuddyPress (2.3.0) 2841 * 2842 * @param string $summary Activity summary HTML. 2843 * @param string $content Content of the activity item. 2844 * @param array $activity The data passed to bp_activity_add() or the values from an Activity obj. 2845 * @param array $extracted_media Media item extracted. See {@link BP_Media_Extractor::extract()} for format. 2799 2846 */ 2800 2847 return apply_filters( 'bp_activity_create_summary', $summary, $content, $activity, $extracted_media ); … … 2826 2873 * 2827 2874 * @param BP_Activity_Activity $activity The activity item to be spammed. 2828 * @param string $sourceOptional. Default is "by_a_person" (ie, a person has2829 * manually marked the activity as spam). BP core also accepts2830 * 'by_akismet'.2875 * @param string $source Optional. Default is "by_a_person" (ie, a person has 2876 * manually marked the activity as spam). BP core also 2877 * accepts 'by_akismet'. 2831 2878 */ 2832 2879 function bp_activity_mark_as_spam( &$activity, $source = 'by_a_person' ) { … … 2861 2908 * 2862 2909 * @param BP_Activity_Activity $activity Activity item being marked as spam. 2863 * @param string $source Source of determination of spam status. For example2864 * "by_a_person" or "by_akismet".2910 * @param string $source Source of determination of spam status. For example 2911 * "by_a_person" or "by_akismet". 2865 2912 */ 2866 2913 do_action( 'bp_activity_mark_as_spam', $activity, $source ); … … 2872 2919 * @since BuddyPress (1.6.0) 2873 2920 * 2874 * @param BP_Activity_Activity $activity The activity item to be hammed. 2875 * @param string $sourceOptional. Default is "by_a_person" (ie, a person has2876 * manually marked the activity as spam). BP core also accepts2877 * 'by_akismet'.2921 * @param BP_Activity_Activity $activity The activity item to be hammed. Passed by reference. 2922 * @param string $source Optional. Default is "by_a_person" (ie, a person has 2923 * manually marked the activity as spam). BP core also accepts 2924 * 'by_akismet'. 2878 2925 */ 2879 2926 function bp_activity_mark_as_ham( &$activity, $source = 'by_a_person' ) { … … 2908 2955 * 2909 2956 * @param BP_Activity_Activity $activity Activity item being marked as ham. 2910 * @param string $source Source of determination of ham status. For example2911 * "by_a_person" or "by_akismet".2957 * @param string $source Source of determination of ham status. For example 2958 * "by_a_person" or "by_akismet". 2912 2959 */ 2913 2960 do_action( 'bp_activity_mark_as_ham', $activity, $source ); … … 3015 3062 * @uses bp_activity_get_meta() 3016 3063 * 3017 * @param string $cache An empty string passed by BP_Embed::parse_oembed() for3018 * functions like this one to filter.3019 * @param int $idThe ID of the activity item.3064 * @param string $cache An empty string passed by BP_Embed::parse_oembed() for 3065 * functions like this one to filter. 3066 * @param int $id The ID of the activity item. 3020 3067 * @param string $cachekey The cache key generated in BP_Embed::parse_oembed(). 3068 * 3021 3069 * @return mixed The cached embeds for this activity item. 3022 3070 */ … … 3035 3083 * @uses bp_activity_update_meta() 3036 3084 * 3037 * @param string $cache An empty string passed by BP_Embed::parse_oembed() for3038 * functions like this one to filter.3085 * @param string $cache An empty string passed by BP_Embed::parse_oembed() for 3086 * functions like this one to filter. 3039 3087 * @param string $cachekey The cache key generated in BP_Embed::parse_oembed(). 3040 * @param int $id The ID of the activity item. 3088 * @param int $id The ID of the activity item. 3089 * 3041 3090 * @return bool True on success, false on failure. 3042 3091 */ -
trunk/src/bp-activity/bp-activity-loader.php
r9819 r9833 133 133 * @param array $main_nav Optional. See BP_Component::setup_nav() for 134 134 * description. 135 * @param array $sub_nav Optional. See BP_Component::setup_nav() for136 * description.135 * @param array $sub_nav Optional. See BP_Component::setup_nav() for 136 * description. 137 137 */ 138 138 public function setup_nav( $main_nav = array(), $sub_nav = array() ) { -
trunk/src/bp-activity/bp-activity-notifications.php
r9819 r9833 37 37 * @uses do_action() To call the 'bp_activity_sent_mention_email' hook 38 38 * 39 * @param int $activity_id The ID of the activity update.39 * @param int $activity_id The ID of the activity update. 40 40 * @param int $receiver_user_id The ID of the user who is receiving the update. 41 41 */ … … 114 114 * @since BuddyPress (1.2.0) 115 115 * 116 * @param string $subject Email notification subject text.116 * @param string $subject Email notification subject text. 117 117 * @param string $poster_name Name of the person who made the @mention. 118 118 */ … … 124 124 * @since BuddyPress (1.2.0) 125 125 * 126 * @param string $message Email notification message text.127 * @param string $poster_name Name of the person who made the @mention.128 * @param string $content Content of the @mention.129 * @param string $message_link URL permalink for the activity message.126 * @param string $message Email notification message text. 127 * @param string $poster_name Name of the person who made the @mention. 128 * @param string $content Content of the @mention. 129 * @param string $message_link URL permalink for the activity message. 130 130 * @param string $settings_link URL permalink for the user's notification settings area. 131 131 */ … … 140 140 * @since BuddyPress (1.5.0) 141 141 * 142 * @param BP_Activity_Activity $activity Activity Item object.143 * @param string $subject Email notification subject text.144 * @param string $message Email notification message text.145 * @param string $content Content of the @mention.142 * @param BP_Activity_Activity $activity Activity Item object. 143 * @param string $subject Email notification subject text. 144 * @param string $message Email notification message text. 145 * @param string $content Content of the @mention. 146 146 * @param int $receiver_user_id The ID of the user who is receiving the update. 147 147 */ … … 174 174 * @uses do_action() To call the 'bp_activity_sent_reply_to_reply_email' hook 175 175 * 176 * @param int $comment_id The comment id. 177 * @param int $commenter_id The ID of the user who posted the comment. 178 * @param array $params {@link bp_activity_new_comment()} 176 * @param int $comment_id The comment id. 177 * @param int $commenter_id The ID of the user who posted the comment. 178 * @param array $params {@link bp_activity_new_comment()} 179 * 180 * @return bool 179 181 */ 180 182 function bp_activity_new_comment_notification( $comment_id = 0, $commenter_id = 0, $params = array() ) { … … 230 232 * @since BuddyPress (1.2.0) 231 233 * 232 * @param string $subject Email notification subject text.234 * @param string $subject Email notification subject text. 233 235 * @param string $poster_name Name of the person who made the comment. 234 236 */ … … 240 242 * @since BuddyPress (1.2.0) 241 243 * 242 * @param string $message Email notification message text.243 * @param string $poster_name Name of the person who made the comment.244 * @param string $content Content of the comment.245 * @param string $thread_link URL permalink for the activity thread.244 * @param string $message Email notification message text. 245 * @param string $poster_name Name of the person who made the comment. 246 * @param string $content Content of the comment. 247 * @param string $thread_link URL permalink for the activity thread. 246 248 * @param string $settings_link URL permalink for the user's notification settings area. 247 249 */ … … 255 257 * @since BuddyPress (1.5.0) 256 258 * 257 * @param int $user_id ID of the original activity item author.258 * @param string $subject Email notification subject text.259 * @param string $message Email notification message text.260 * @param int $comment_id ID for the newly received comment.259 * @param int $user_id ID of the original activity item author. 260 * @param string $subject Email notification subject text. 261 * @param string $message Email notification message text. 262 * @param int $comment_id ID for the newly received comment. 261 263 * @param int $commenter_id ID of the user who made the comment. 262 * @param array $params Arguments used with the original activity comment.264 * @param array $params Arguments used with the original activity comment. 263 265 */ 264 266 do_action( 'bp_activity_sent_reply_to_update_email', $original_activity->user_id, $subject, $message, $comment_id, $commenter_id, $params ); … … 318 320 * @since BuddyPress (1.2.0) 319 321 * 320 * @param string $subject Email notification subject text.322 * @param string $subject Email notification subject text. 321 323 * @param string $poster_name Name of the person who made the comment reply. 322 324 */ … … 328 330 * @since BuddyPress (1.2.0) 329 331 * 330 * @param string $message Email notification message text.331 * @param string $poster_name Name of the person who made the comment reply.332 * @param string $content Content of the comment reply.332 * @param string $message Email notification message text. 333 * @param string $poster_name Name of the person who made the comment reply. 334 * @param string $content Content of the comment reply. 333 335 * @param string $settings_link URL permalink for the user's notification settings area. 334 * @param string $thread_link URL permalink for the activity thread.336 * @param string $thread_link URL permalink for the activity thread. 335 337 */ 336 338 $message = apply_filters( 'bp_activity_new_comment_notification_comment_author_message', $message, $poster_name, $content, $settings_link, $thread_link ); … … 343 345 * @since BuddyPress (1.5.0) 344 346 * 345 * @param int $user_id ID of the parent activity item author.346 * @param string $subject Email notification subject text.347 * @param string $message Email notification message text.348 * @param int $comment_id ID for the newly received comment.347 * @param int $user_id ID of the parent activity item author. 348 * @param string $subject Email notification subject text. 349 * @param string $message Email notification message text. 350 * @param int $comment_id ID for the newly received comment. 349 351 * @param int $commenter_id ID of the user who made the comment. 350 * @param array $params Arguments used with the original activity comment.352 * @param array $params Arguments used with the original activity comment. 351 353 */ 352 354 do_action( 'bp_activity_sent_reply_to_reply_email', $parent_comment->user_id, $subject, $message, $comment_id, $commenter_id, $params ); … … 358 360 * 359 361 * @since BuddyPress (1.9.0) 360 * @param int $comment_id 362 * 363 * @param int $comment_id 361 364 * @param array $params 362 365 */ … … 380 383 * @uses do_action() To call 'activity_format_notifications' hook. 381 384 * 382 * @param string $action The type of activity item. Just 'new_at_mention' for now. 383 * @param int $item_id The activity ID. 384 * @param int $secondary_item_id In the case of at-mentions, this is the mentioner's ID. 385 * @param int $total_items The total number of notifications to format. 386 * @param string $format 'string' to get a BuddyBar-compatible notification, 'array' otherwise. 385 * @param string $action The type of activity item. Just 'new_at_mention' for now. 386 * @param int $item_id The activity ID. 387 * @param int $secondary_item_id In the case of at-mentions, this is the mentioner's ID. 388 * @param int $total_items The total number of notifications to format. 389 * @param string $format 'string' to get a BuddyBar-compatible notification, 'array' otherwise. 390 * 387 391 * @return string $return Formatted @mention notification. 388 392 */ … … 418 422 * @since BuddyPress (1.5.0) 419 423 * 420 * @param string $string HTML anchor tag for the mention.424 * @param string $string HTML anchor tag for the mention. 421 425 * @param string $at_mention_link The permalink for the mention. 422 * @param int $total_items How many items being notified about.423 * @param int $activity_id ID of the activity item being formatted.424 * @param int $poster_user_id ID of the user posting the mention.426 * @param int $total_items How many items being notified about. 427 * @param int $activity_id ID of the activity item being formatted. 428 * @param int $poster_user_id ID of the user posting the mention. 425 429 */ 426 430 $return = apply_filters( 'bp_activity_' . $amount . '_at_mentions_notification', '<a href="' . esc_url( $at_mention_link ) . '" title="' . esc_attr( $at_mention_title ) . '">' . esc_html( $text ) . '</a>', $at_mention_link, (int) $total_items, $activity_id, $poster_user_id ); … … 436 440 * @since BuddyPress (1.5.0) 437 441 * 438 * @param array $array Array holding the content and permalink for the mention notification.442 * @param array $array Array holding the content and permalink for the mention notification. 439 443 * @param string $at_mention_link The permalink for the mention. 440 * @param int $total_items How many items being notified about.441 * @param int $activity_id ID of the activity item being formatted.442 * @param int $poster_user_id ID of the user posting the mention.444 * @param int $total_items How many items being notified about. 445 * @param int $activity_id ID of the activity item being formatted. 446 * @param int $poster_user_id ID of the user posting the mention. 443 447 */ 444 448 $return = apply_filters( 'bp_activity_' . $amount . '_at_mentions_notification', array( … … 453 457 * @since BuddyPress (1.2.0) 454 458 * 455 * @param string $action The type of activity item.456 * @param int $item_id The activity ID.459 * @param string $action The type of activity item. 460 * @param int $item_id The activity ID. 457 461 * @param int $secondary_item_id @mention mentioner ID. 458 * @param int $total_items Total amount of items to format.462 * @param int $total_items Total amount of items to format. 459 463 */ 460 464 do_action( 'activity_format_notifications', $action, $item_id, $secondary_item_id, $total_items ); … … 473 477 * @since BuddyPress (1.9.0) 474 478 * 475 * @param obj $activity479 * @param object $activity 476 480 * @param string $subject (not used) 477 481 * @param string $message (not used) 478 482 * @param string $content (not used) 479 * @param int $receiver_user_id483 * @param int $receiver_user_id 480 484 */ 481 485 function bp_activity_at_mention_add_notification( $activity, $subject, $message, $content, $receiver_user_id ) { … … 519 523 * 520 524 * @since BuddyPress (2.0.0) 525 * 526 * @param object BP_Activity_Activity 521 527 */ 522 528 function bp_activity_remove_screen_notifications_single_activity_permalink( $activity ) { -
trunk/src/bp-activity/bp-activity-screens.php
r9819 r9833 314 314 * @since BuddyPress (1.2.0) 315 315 * 316 * @param BP_Activity_Activity $activity Object representing the current activity item being displayed.317 * @param bool $has_access Whether or not the current user has access to view activity.316 * @param BP_Activity_Activity $activity Object representing the current activity item being displayed. 317 * @param bool $has_access Whether or not the current user has access to view activity. 318 318 */ 319 319 do_action( 'bp_activity_screen_single_activity_permalink', $activity, $has_access ); … … 476 476 * 477 477 * @param string $templates The templates from bp_get_theme_compat_templates(). 478 * 478 479 * @return array $templates Array of custom templates to look for. 479 480 */ … … 536 537 * 537 538 * @param string $templates The templates from bp_get_theme_compat_templates(). 539 * 538 540 * @return array $templates Array of custom templates to look for. 539 541 */ -
trunk/src/bp-activity/bp-activity-template.php
r9828 r9833 227 227 * 'include'. Default values for 'per_page' and 'display_comments' 228 228 * differ from the originating function, and are described below. 229 * @type string $page_argThe string used as a query parameter in230 * pagination links. Default: 'acpage'.231 * @type array|bool $includePass an array of activity IDs to232 * retrieve only those items, or false to noop the 'include'233 * parameter. 'include' differs from 'in' in that 'in' forms234 * an IN clause that works in conjunction with other filters235 * passed to the function, while 'include' is interpreted as236 * an exact list of items to retrieve, which skips all other237 * filter-related parameters. Default: false.238 * @type int|bool $per_pageDefault: 20.229 * @type string $page_arg The string used as a query parameter in 230 * pagination links. Default: 'acpage'. 231 * @type array|bool $include Pass an array of activity IDs to 232 * retrieve only those items, or false to noop the 'include' 233 * parameter. 'include' differs from 'in' in that 'in' forms 234 * an IN clause that works in conjunction with other filters 235 * passed to the function, while 'include' is interpreted as 236 * an exact list of items to retrieve, which skips all other 237 * filter-related parameters. Default: false. 238 * @type int|bool $per_page Default: 20. 239 239 * @type string|bool $display_comments Default: 'threaded'. 240 240 * } … … 523 523 * @uses apply_filters() To call the 'bp_has_activities' hook. 524 524 * 525 * @param array $args {525 * @param array|string $args { 526 526 * Arguments for limiting the contents of the activity loop. Most arguments 527 527 * are in the same format as {@link BP_Activity_Activity::get()}. However, … … 1422 1422 * @uses bp_get_activity_avatar() 1423 1423 * 1424 * @param array $args See {@link bp_get_activity_avatar()} for description.1424 * @param array|string $args See {@link bp_get_activity_avatar()} for description. 1425 1425 */ 1426 1426 function bp_activity_avatar( $args = '' ) { … … 1441 1441 * @uses apply_filters() To call the 'bp_get_activity_avatar' hook 1442 1442 * 1443 * @param array $args {1443 * @param array|string $args { 1444 1444 * Arguments are listed here with an explanation of their defaults. 1445 1445 * For more information about the arguments, see 1446 1446 * {@link bp_core_fetch_avatar()}. 1447 * @type string $altDefault: 'Profile picture of [user name]' if1448 * activity user name is available, otherwise 'Profile picture'.1449 * @type string $classDefault: 'avatar'.1450 * @type string|bool $email Default: Email of the activity's1451 * associated user, if available. Otherwise false.1452 * @type string $typeDefault: 'full' when viewing a single activity1453 * permalink page, otherwise 'thumb'.1454 * @type int|bool $user_id Default: ID of the activity's user.1447 * @type string $alt Default: 'Profile picture of [user name]' if 1448 * activity user name is available, otherwise 'Profile picture'. 1449 * @type string $class Default: 'avatar'. 1450 * @type string|bool $email Default: Email of the activity's 1451 * associated user, if available. Otherwise false. 1452 * @type string $type Default: 'full' when viewing a single activity 1453 * permalink page, otherwise 'thumb'. 1454 * @type int|bool $user_id Default: ID of the activity's user. 1455 1455 * } 1456 1456 * @return string User avatar string. … … 1557 1557 * @uses bp_get_activity_secondary_avatar() 1558 1558 * 1559 * @param array $args See {@link bp_get_activity_secondary_avatar} for description.1559 * @param array|string $args See {@link bp_get_activity_secondary_avatar} for description. 1560 1560 */ 1561 1561 function bp_activity_secondary_avatar( $args = '' ) { … … 1579 1579 * @param array $args { 1580 1580 * For a complete description of arguments, see {@link bp_core_fetch_avatar()}. 1581 * @type string $altDefault value varies based on current activity1582 * item component.1583 * @type string $typeDefault: 'full' when viewing a single activity1584 * permalink page, otherwise 'thumb'.1585 * @type string $classDefault: 'avatar'.1586 * @type string|bool $email Default: email of the activity's user.1587 * @type int|bool $user_id Default: ID of the activity's user.1581 * @type string $alt Default value varies based on current activity 1582 * item component. 1583 * @type string $type Default: 'full' when viewing a single activity 1584 * permalink page, otherwise 'thumb'. 1585 * @type string $class Default: 'avatar'. 1586 * @type string|bool $email Default: email of the activity's user. 1587 * @type int|bool $user_id Default: ID of the activity's user. 1588 1588 * } 1589 1589 * @return string The secondary avatar … … 1715 1715 * @since BuddyPress (1.7.0) 1716 1716 * 1717 * @param string $link Link to wrap the avatar image in.1717 * @param string $link Link to wrap the avatar image in. 1718 1718 * @param string $component Activity component being acted on. 1719 1719 */ … … 1725 1725 * @since BuddyPress (1.2.10) 1726 1726 * 1727 * @param string Formatted HTML <img> element, or raw avatar URL.1727 * @param string $avatar Formatted HTML <img> element, or raw avatar URL. 1728 1728 */ 1729 1729 $avatar = apply_filters( 'bp_get_activity_secondary_avatar', $avatar ); … … 1766 1766 * @type bool $no_timestamp Whether to exclude the timestamp. 1767 1767 * } 1768 * 1768 1769 * @return string The activity action. 1769 1770 */ … … 1924 1925 * 1925 1926 * @param string $content The activity content. 1927 * 1926 1928 * @return string The activity content with the metadata string attached. 1927 1929 */ … … 1992 1994 * @uses apply_filters() To call the 'bp_activity_user_can_delete' hook 1993 1995 * 1994 * @param object $activity Optional. Falls back on the current item in the loop. 1996 * @param object|bool $activity Optional. Falls back on the current item in the loop. 1997 * 1995 1998 * @return bool True if can delete, false otherwise. 1996 1999 */ … … 2038 2041 * 2039 2042 * @param bool $can_delete Whether the user can delete the item. 2040 * @param object $activity Current activity item object.2043 * @param object $activity Current activity item object. 2041 2044 */ 2042 2045 return (bool) apply_filters( 'bp_activity_user_can_delete', $can_delete, $activity ); … … 2051 2054 * @uses bp_get_activity_parent_content() 2052 2055 * 2053 * @param array $args See {@link bp_get_activity_parent_content} for description.2056 * @param array|string $args See {@link bp_get_activity_parent_content} for description. 2054 2057 */ 2055 2058 function bp_activity_parent_content( $args = '' ) { … … 2131 2134 * 2132 2135 * @return bool|int False if parent activity can't be found, otherwise 2133 * the parent activity's user ID.2136 * the parent activity's user ID. 2134 2137 */ 2135 2138 function bp_get_activity_parent_user_id() { … … 2207 2210 * @todo deprecate $args param 2208 2211 * 2209 * @param array $args See {@link bp_activity_get_comments} for description.2212 * @param array|string $args See {@link bp_activity_get_comments} for description. 2210 2213 */ 2211 2214 function bp_activity_comments( $args = '' ) { … … 2227 2230 * @global object $activities_template {@link BP_Activity_Template} 2228 2231 * @uses bp_activity_recurse_comments() 2232 * 2233 * @return bool 2229 2234 */ 2230 2235 function bp_activity_get_comments( $args = '' ) { … … 2250 2255 * @global object $activities_template {@link BP_Activity_Template} 2251 2256 * @uses locate_template() 2257 * 2258 * @return bool|string 2252 2259 */ 2253 2260 function bp_activity_recurse_comments( $comment ) { … … 2309 2316 * 2310 2317 * @return object|bool $current_comment The activity comment currently being 2311 * displayed. False on failure.2318 * displayed. False on failure. 2312 2319 */ 2313 2320 function bp_activity_current_comment() { … … 2348 2355 * @uses apply_filters() To call the 'bp_activity_comment_id' hook. 2349 2356 * 2350 * @return int|bool $comment_id The ID of the activity comment 2351 * currentlybeing displayed, false if none is found.2357 * @return int|bool $comment_id The ID of the activity comment currently 2358 * being displayed, false if none is found. 2352 2359 */ 2353 2360 function bp_get_activity_comment_id() { … … 2386 2393 * 2387 2394 * @return int|bool $user_id The user_id of the author of the displayed 2388 * activity comment. False on failure.2395 * activity comment. False on failure. 2389 2396 */ 2390 2397 function bp_get_activity_comment_user_id() { … … 2503 2510 * 2504 2511 * @return string|bool $date_recorded Time since the activity was recorded, 2505 * in the form "%s ago". False on failure.2512 * in the form "%s ago". False on failure. 2506 2513 */ 2507 2514 function bp_get_activity_comment_date_recorded() { … … 2576 2583 * 2577 2584 * @return string $link The nonced URL for deleting the current 2578 * activity comment.2585 * activity comment. 2579 2586 */ 2580 2587 function bp_get_activity_comment_delete_link() { … … 2693 2700 * 2694 2701 * @param object $comment Activity comment object. 2695 * @param int $count The current iteration count.2702 * @param int $count The current iteration count. 2696 2703 * 2697 2704 * @return int $count The activity comment count. … … 2716 2723 * 2717 2724 * @param int $new_count New total count for the current comment. 2718 * @param object $comment Activity comment object.2719 * @param int $count Current iteration count for the current comment.2725 * @param object $comment Activity comment object. 2726 * @param int $count Current iteration count for the current comment. 2720 2727 */ 2721 2728 return apply_filters( 'bp_activity_recurse_comment_count', $new_count, $comment, $count ); … … 2803 2810 * 2804 2811 * @return string|bool The activity comment form no JavaScript 2805 * display CSS. False on failure.2812 * display CSS. False on failure. 2806 2813 */ 2807 2814 function bp_get_activity_comment_form_nojs_display() { … … 2958 2965 * @since BuddyPress (1.8.0) 2959 2966 * 2960 * @param string $link Activity comment permalink.2967 * @param string $link Activity comment permalink. 2961 2968 * @param int $comment_id ID for the current activity comment. 2962 2969 */ … … 3127 3134 * 3128 3135 * @return string $link Activity delete link. Contains $redirect_to arg 3129 * if on single activity page.3136 * if on single activity page. 3130 3137 */ 3131 3138 function bp_get_activity_delete_link() { … … 3177 3184 * 3178 3185 * @return string $link Activity delete link. Contains $redirect_to arg 3179 * if on single activity page.3186 * if on single activity page. 3180 3187 */ 3181 3188 function bp_get_activity_delete_url() { … … 3230 3237 * 3231 3238 * @param int $user_id If empty, will fall back on displayed user. 3239 * 3232 3240 * @return string|bool $latest_update The activity latest update link. 3233 * False on failure3241 * False on failure 3234 3242 */ 3235 3243 function bp_get_activity_latest_update( $user_id = 0 ) { … … 3281 3289 * @uses bp_get_activity_filter_links() 3282 3290 * 3283 * @param array $args See {@link bp_get_activity_filter_links()} for description.3291 * @param array|bool $args See {@link bp_get_activity_filter_links()} for description. 3284 3292 */ 3285 3293 function bp_activity_filter_links( $args = false ) { … … 3300 3308 * @uses apply_filters() To call the 'bp_get_activity_filter_links' hook. 3301 3309 * 3302 * @param array $args {3310 * @param array|bool $args { 3303 3311 * @type string $style The type of markup to use for the links. 3304 * 'list', 'paragraph', or 'span'. Default: 'list'.3312 * 'list', 'paragraph', or 'span'. Default: 'list'. 3305 3313 * } 3306 3314 * @return string|bool $component_links The activity filter links. … … 3364 3372 * @since BuddyPress (1.1.0) 3365 3373 * 3366 * @param string $link The URL for the current component.3374 * @param string $link The URL for the current component. 3367 3375 * @param string $component The current component getting links constructed for. 3368 3376 */ … … 3441 3449 * @since BuddyPress (1.5.0) 3442 3450 * 3443 * @param bool $can_comment Status on if activity can be commented on.3451 * @param bool $can_comment Status on if activity can be commented on. 3444 3452 * @param string $activity_action Current activity action being checked on. 3445 3453 */ … … 3489 3497 * 3490 3498 * @param bool $can_comment Status on if activity reply can be commented on. 3491 * @param string $comment Current comment being checked on.3499 * @param string $comment Current comment being checked on. 3492 3500 */ 3493 3501 return (bool) apply_filters( 'bp_activity_can_comment_reply', $can_comment, $comment ); … … 3540 3548 * 3541 3549 * @param int $user_id ID of user being queried. Default: displayed user ID. 3550 * 3542 3551 * @return int The total favorite count for the specified user. 3543 3552 */ … … 3591 3600 * 3592 3601 * @param int $user_id ID of user being queried. Default: displayed user ID. 3602 * 3593 3603 * @return int The total mention count for the specified user. 3594 3604 */ … … 3668 3678 * @param array $activity Array of activities generated from {@link bp_activity_get()}. 3669 3679 * @param array $activity_ids Used for recursion purposes in this function. 3680 * 3670 3681 * @return array 3671 3682 */ … … 3696 3707 * @uses bp_get_mentioned_user_display_name() 3697 3708 * 3698 * @param int|string $user_id_or_username See {@link bp_get_mentioned_user_display_name()}.3709 * @param int|string|bool $user_id_or_username See {@link bp_get_mentioned_user_display_name()}. 3699 3710 */ 3700 3711 function bp_mentioned_user_display_name( $user_id_or_username = false ) { … … 3710 3721 * @uses apply_filters() To call the 'bp_get_mentioned_user_display_name' hook. 3711 3722 * 3712 * @param int|string User ID or username. 3723 * @param int|string|bool User ID or username. 3724 * 3713 3725 * @return string The mentioned user's display name. 3714 3726 */ … … 3728 3740 * @since BuddyPress (1.2.0) 3729 3741 * 3730 * @param string $name Display name for the mentioned user.3742 * @param string $name Display name for the mentioned user. 3731 3743 * @param int|string $user_id_or_username User ID or username use for query. 3732 3744 */ … … 3742 3754 * @uses bp_get_send_public_message_button() 3743 3755 * 3744 * @param array $args See {@link bp_get_send_public_message_button()}.3756 * @param array|string $args See {@link bp_get_send_public_message_button()}. 3745 3757 */ 3746 3758 function bp_send_public_message_button( $args = '' ) { … … 3758 3770 * @uses apply_filters() To call the 'bp_get_send_public_message_button' hook. 3759 3771 * 3760 * @param array $args {3772 * @param array|string $args { 3761 3773 * All arguments are optional. See {@link BP_Button} for complete 3762 3774 * descriptions. 3763 * @type string $id Default: 'public_message'.3764 * @type string $component Default: 'activity'.3765 * @type bool $must_be_logged_in Default: true.3766 * @type bool $block_selfDefault: true.3767 * @type string $wrapper_id Default: 'post-mention'.3768 * @type string $link_href Default: the public message link for3769 * the current member in the loop.3770 * @type string $link_title Default: 'Send a public message on your3771 * activity stream.'.3772 * @type string $link_text Default: 'Public Message'.3773 * @type string $link_class Default: 'activity-button mention'.3775 * @type string $id Default: 'public_message'. 3776 * @type string $component Default: 'activity'. 3777 * @type bool $must_be_logged_in Default: true. 3778 * @type bool $block_self Default: true. 3779 * @type string $wrapper_id Default: 'post-mention'. 3780 * @type string $link_href Default: the public message link for 3781 * the current member in the loop. 3782 * @type string $link_title Default: 'Send a public message on your 3783 * activity stream.'. 3784 * @type string $link_text Default: 'Public Message'. 3785 * @type string $link_class Default: 'activity-button mention'. 3774 3786 * } 3775 3787 * @return string The button for sending a public message. … … 3899 3911 * 3900 3912 * @param string $retval HTML markup for the list of avatars. 3901 * @param array $r Array of arguments used for each avatar.3913 * @param array $r Array of arguments used for each avatar. 3902 3914 * @param array $output Array of each avatar found, before imploded into single string. 3903 3915 */ … … 3935 3947 * 3936 3948 * @param array $comments Array of {@link BP_Activity_Activity} items. 3949 * 3937 3950 * @return array Array of user IDs. 3938 3951 */ … … 4005 4018 * @since BuddyPress (1.7.0) 4006 4019 * 4007 * @param string $output Optional. Either 'select' or 'checkbox'. Default: 'select'.4008 * @param array $args {4020 * @param string $output Optional. Either 'select' or 'checkbox'. Default: 'select'. 4021 * @param array|string $args { 4009 4022 * Optional extra arguments. 4010 * @type string $checkbox_name When returning checkboxes, sets the 'name'4011 * attribute.4012 * @type array|string $selected A list of types that should be checked/4013 * selected.4023 * @type string $checkbox_name When returning checkboxes, sets the 'name' 4024 * attribute. 4025 * @type array|string $selected A list of types that should be checked/ 4026 * selected. 4014 4027 * } 4015 4028 */ … … 4049 4062 * @since BuddyPress (1.7.0) 4050 4063 * 4051 * @param array $args Array of arguments passed into function.4052 * @param string $type Activity type being rendered in the output.4064 * @param array $args Array of arguments passed into function. 4065 * @param string $type Activity type being rendered in the output. 4053 4066 * @param string $description Description of the activity type being rendered. 4054 4067 */ … … 4425 4438 * 4426 4439 * @param string $context The current context. 'activity', 'member', 4427 * 'member_groups', 'group'.4440 * 'member_groups', 'group'. 4428 4441 * @uses bp_get_activity_show_filters() 4429 4442 */ … … 4437 4450 * 4438 4451 * @param string $context The current context. 'activity', 'member', 4439 * 'member_groups', 'group' 4452 * 'member_groups', 'group' 4453 * 4440 4454 * @return string HTML for <option> values. 4441 4455 */ … … 4487 4501 * @since BuddyPress (2.2.0) 4488 4502 * 4489 * @param array $filters Array of filter options for the given context, in the following format: $option_value => $option_name.4503 * @param array $filters Array of filter options for the given context, in the following format: $option_value => $option_name. 4490 4504 * @param string $context Context for the filter. 'activity', 'member', 'member_groups', 'group'. 4491 4505 */ … … 4506 4520 * @since BuddyPress (2.1.0) 4507 4521 * 4508 * @param string $output HTML output for the activity filter dropdown.4522 * @param string $output HTML output for the activity filter dropdown. 4509 4523 * @param array $filters Array of filter options for the given context, in the following format: $option_value => $option_name. 4510 4524 * @param string $context Context for the filter. 'activity', 'member', 'member_groups', 'group'. -
trunk/src/bp-activity/classes/class-bp-activity-activity.php
r9819 r9833 123 123 * Constructor method. 124 124 * 125 * @param int $id Optional. The ID of a specific activity item.125 * @param int|bool $id Optional. The ID of a specific activity item. 126 126 */ 127 127 public function __construct( $id = false ) { … … 212 212 * @since BuddyPress (1.0.0) 213 213 * 214 * @param BP_Activity_Activity Current instance of the activity item being saved.214 * @param BP_Activity_Activity $this Current instance of the activity item being saved. Passed by reference. 215 215 */ 216 216 do_action_ref_array( 'bp_activity_before_save', array( &$this ) ); … … 249 249 * @since BuddyPress (1.0.0) 250 250 * 251 * @param BP_Activity_Activity Reference to current instance of activity being saved.251 * @param BP_Activity_Activity $this Current instance of activity item being saved. Passed by reference. 252 252 */ 253 253 do_action_ref_array( 'bp_activity_after_save', array( &$this ) ); … … 460 460 * 461 461 * @param array $where_conditions Current conditions for MySQL WHERE statement. 462 * @param array $r Parsed arguments passed into method.463 * @param string $select_sql Current SELECT MySQL statement at point of execution.464 * @param string $from_sql Current FROM MySQL statement at point of execution.465 * @param string $join_sql Current INNER JOIN MySQL statement at point of execution.462 * @param array $r Parsed arguments passed into method. 463 * @param string $select_sql Current SELECT MySQL statement at point of execution. 464 * @param string $from_sql Current FROM MySQL statement at point of execution. 465 * @param string $join_sql Current INNER JOIN MySQL statement at point of execution. 466 466 */ 467 467 $where_conditions = apply_filters( 'bp_activity_get_where_conditions', $where_conditions, $r, $select_sql, $from_sql, $join_sql ); … … 509 509 * @since BuddyPress (2.0.0) 510 510 * 511 * @param bool Whether to use legacy structure or not.512 * @param BP_Activity_Activity Current method being called.513 * @param array $r Parsed arguments passed into method.511 * @param bool $value Whether to use legacy structure or not. 512 * @param BP_Activity_Activity $value Current method being called. 513 * @param array $r Parsed arguments passed into method. 514 514 */ 515 515 if ( apply_filters( 'bp_use_legacy_activity_query', false, __METHOD__, $r ) ) { … … 532 532 * @since BuddyPress (1.5.0) 533 533 * 534 * @param string Concatenated MySQL statement pieces to be query results with for legacy query.534 * @param string $value Concatenated MySQL statement pieces to be query results with for legacy query. 535 535 * @param string $select_sql Final SELECT MySQL statement portion for legacy query. 536 * @param string $from_sql Final FROM MySQL statement portion for legacy query.537 * @param string $where_sql Final WHERE MySQL statement portion for legacy query.538 * @param string $sort Final sort direction for legacy query.536 * @param string $from_sql Final FROM MySQL statement portion for legacy query. 537 * @param string $where_sql Final WHERE MySQL statement portion for legacy query. 538 * @param string $sort Final sort direction for legacy query. 539 539 */ 540 540 $activities = $wpdb->get_results( apply_filters( 'bp_activity_get_user_join_filter', "{$select_sql} {$from_sql} {$join_sql} {$where_sql} ORDER BY a.date_recorded {$sort}", $select_sql, $from_sql, $where_sql, $sort, $pag_sql ) ); … … 557 557 * 558 558 * @param string $activity_ids_sql MySQL statement used to query for Activity IDs. 559 * @param array $r Array of arguments passed into method.559 * @param array $r Array of arguments passed into method. 560 560 */ 561 561 $activity_ids_sql = apply_filters( 'bp_activity_paged_activities_sql', $activity_ids_sql, $r ); … … 607 607 * @since BuddyPress (1.5.0) 608 608 * 609 * @param string MySQL statement used to query for total activities.609 * @param string $value MySQL statement used to query for total activities. 610 610 * @param string $where_sql MySQL WHERE statement portion. 611 * @param string $sort sort direction for query.611 * @param string $sort Sort direction for query. 612 612 */ 613 613 $total_activities_sql = apply_filters( 'bp_activity_total_activities_sql', "SELECT count(DISTINCT a.id) FROM {$bp->activity->table_name} a {$join_sql} {$where_sql}", $where_sql, $sort ); … … 632 632 * 633 633 * @param array $activity_ids Array of activity IDs. 634 * 634 635 * @return array 635 636 */ … … 696 697 * 697 698 * @param array $activities Activities array. 699 * 698 700 * @return array 699 701 */ … … 736 738 * 737 739 * @param array $activities Array of activities. 740 * 741 * @return array $activities Array of activities. 738 742 */ 739 743 protected static function prefetch_object_data( $activities ) { … … 760 764 * 761 765 * @param array $activities Array of activities. 766 * 762 767 * @return array 763 768 */ … … 787 792 * 788 793 * @param array $meta_query An array of meta_query filters. See the 789 * documentation for WP_Meta_Query for details. 794 * documentation for WP_Meta_Query for details. 795 * 790 796 * @return array $sql_array 'join' and 'where' clauses. 791 797 */ … … 827 833 * 828 834 * @param array $date_query An array of date_query parameters. See the 829 * documentation for the first parameter of WP_Date_Query. 835 * documentation for the first parameter of WP_Date_Query. 836 * 830 837 * @return string 831 838 */ … … 855 862 * @param array $r Current activity arguments. Same as those of BP_Activity_Activity::get(), 856 863 * but merged with defaults. 864 * 857 865 * @return array 'sql' WHERE SQL string and 'override' activity args 858 866 */ … … 956 964 * @deprecated Use BP_Activity_Activity::get() with an 'in' parameter instead. 957 965 * 958 * @param mixed $activity_idsArray or comma-separated string of activity IDs to retrieve959 * @param int $maxMaximum number of results to return. (Optional; default is no maximum)960 * @param int $pageThe set of results that the user is viewing. Used in pagination. (Optional; default is 1)961 * @param int $per_pageSpecifies how many results per page. Used in pagination. (Optional; default is 25)962 * @param string MySQL column sort; ASC or DESC. (Optional; default is DESC)963 * @param bool $display_comments Retrieve an activity item's associated comments or not. (Optional; default is false)966 * @param mixed $activity_ids Array or comma-separated string of activity IDs to retrieve 967 * @param int|bool $max Maximum number of results to return. (Optional; default is no maximum) 968 * @param int $page The set of results that the user is viewing. Used in pagination. (Optional; default is 1) 969 * @param int $per_page Specifies how many results per page. Used in pagination. (Optional; default is 25) 970 * @param string $sort MySQL column sort; ASC or DESC. (Optional; default is DESC) 971 * @param bool $display_comments Retrieve an activity item's associated comments or not. (Optional; default is false) 964 972 * @return array 965 973 */ … … 1041 1049 * 1042 1050 * @param array $args { 1043 * @int $idOptional. The ID of a specific item to delete.1044 * @string $action Optional. The action to filter by.1045 * @string $content Optional. The content to filter by.1046 * @string $component Optional. The component name to filter by.1047 * @string $type Optional. The activity type to filter by.1048 * @string $primary_link Optional. The primary URL to filter by.1049 * @int $user_idOptional. The user ID to filter by.1050 * @int $item_idOptional. The associated item ID to filter by.1051 * @int $secondary_item_id Optional. The secondary associated item ID to filter by.1052 * @string $date_recorded Optional. The date to filter by.1053 * @int $hide_sitewideOptional. Default: false.1051 * @int $id Optional. The ID of a specific item to delete. 1052 * @string $action Optional. The action to filter by. 1053 * @string $content Optional. The content to filter by. 1054 * @string $component Optional. The component name to filter by. 1055 * @string $type Optional. The activity type to filter by. 1056 * @string $primary_link Optional. The primary URL to filter by. 1057 * @int $user_id Optional. The user ID to filter by. 1058 * @int $item_id Optional. The associated item ID to filter by. 1059 * @int $secondary_item_id Optional. The secondary associated item ID to filter by. 1060 * @string $date_recorded Optional. The date to filter by. 1061 * @int $hide_sitewide Optional. Default: false. 1054 1062 * } 1063 * 1055 1064 * @return array|bool An array of deleted activity IDs on success, false on failure. 1056 1065 */ … … 1216 1225 * 1217 1226 * @param array $activity_ids Activity IDs whose comments should be deleted. 1218 * @param bool $delete_meta Should we delete the activity meta items for these comments? 1227 * @param bool $delete_meta Should we delete the activity meta items for these comments? 1228 * 1219 1229 * @return bool True on success. 1220 1230 */ … … 1245 1255 * 1246 1256 * @param array $activity_ids Activity IDs whose meta should be deleted. 1257 * 1247 1258 * @return bool True on success. 1248 1259 */ … … 1264 1275 * @global wpdb $wpdb WordPress database object 1265 1276 * 1266 * @param array $activities Activities to fetch comments for. 1267 * @param bool $spam Optional. 'ham_only' (default), 'spam_only' or 'all'. 1277 * @param array $activities Activities to fetch comments for. 1278 * @param string $spam Optional. 'ham_only' (default), 'spam_only' or 'all'. 1279 * 1268 1280 * @return array The updated activities with nested comments. 1269 1281 */ … … 1294 1306 * @global wpdb $wpdb WordPress database object. 1295 1307 * 1296 * @param int $activity_id Activity ID to fetch comments for. 1297 * @param int $left Left-most node boundary. 1298 * @param into $right Right-most node boundary. 1299 * @param bool $spam Optional. 'ham_only' (default), 'spam_only' or 'all'. 1300 * @param int $top_level_parent_id Optional. The id of the root-level parent activity item. 1308 * @param int $activity_id Activity ID to fetch comments for. 1309 * @param int $left Left-most node boundary. 1310 * @param int $right Right-most node boundary. 1311 * @param string $spam Optional. 'ham_only' (default), 'spam_only' or 'all'. 1312 * @param int $top_level_parent_id Optional. The id of the root-level parent activity item. 1313 * 1301 1314 * @return array The updated activities with nested comments. 1302 1315 */ … … 1348 1361 * @since BuddyPress (2.0.0) 1349 1362 * 1350 * @param bool Whether or not to use the legacy query.1351 * @param BP_Activity_Activity Magic method referring to currently called method.1352 * @param array $func_argsArray of the method's argument list.1363 * @param bool $value Whether or not to use the legacy query. 1364 * @param BP_Activity_Activity $value Magic method referring to currently called method. 1365 * @param array $func_args Array of the method's argument list. 1353 1366 */ 1354 1367 if ( apply_filters( 'bp_use_legacy_activity_query', false, __METHOD__, $func_args ) ) { … … 1359 1372 * @since BuddyPress (1.5.0) 1360 1373 * 1361 * @param string Prepared statement for the activity query.1374 * @param string $value Prepared statement for the activity query. 1362 1375 * @param int $activity_id Activity ID to fetch comments for. 1363 * @param int $left Left-most node boundary.1364 * @param int $right Right-most node boundary.1365 * @param string $spam_sql SQL Statement portion to differentiate between ham or spam.1376 * @param int $left Left-most node boundary. 1377 * @param int $right Right-most node boundary. 1378 * @param string $spam_sql SQL Statement portion to differentiate between ham or spam. 1366 1379 */ 1367 1380 $sql = apply_filters( 'bp_activity_comments_user_join_filter', $wpdb->prepare( "SELECT a.*, u.user_email, u.user_nicename, u.user_login, u.display_name{$fullname_select} FROM {$bp->activity->table_name} a, {$wpdb->users} u{$fullname_from} WHERE u.ID = a.user_id {$fullname_where} AND a.type = 'activity_comment' {$spam_sql} AND a.item_id = %d AND a.mptt_left > %d AND a.mptt_left < %d ORDER BY a.date_recorded ASC", $top_level_parent_id, $left, $right ), $activity_id, $left, $right, $spam_sql ); … … 1489 1502 * 1490 1503 * @param int $parent_id ID of an activity or activity comment. 1504 * 1491 1505 * @return object Numerically indexed array of child comments. 1492 1506 */ … … 1507 1521 * the activity table, but these items are not full-fledged 1508 1522 * activity items.) Default: true. 1523 * 1509 1524 * @return array List of component names. 1510 1525 */ … … 1527 1542 * 1528 1543 * @param int $limit Optional. Number of items to fetch. Default: 35. 1544 * 1529 1545 * @return array $activity_feed List of activity items, with RSS data added. 1530 1546 */ … … 1551 1567 * @see BP_Activity_Activity::get_filter_sql() 1552 1568 * 1553 * @param string $field The database field.1569 * @param string $field The database field. 1554 1570 * @param array|bool $items The values for the IN clause, or false when none are found. 1571 * 1572 * @return string|bool. 1555 1573 */ 1556 1574 public static function get_in_operator_sql( $field, $items ) { … … 1587 1605 * @param array $filter_array { 1588 1606 * Fields and values to filter by. 1589 * @type array|string|id $user_id User ID(s). 1590 * @type array|string $object Corresponds to the 'component' 1591 * column in the database. 1592 * @type array|string $action Corresponds to the 'type' column 1593 * in the database. 1594 * @type array|string|int $primary_id Corresponds to the 'item_id' 1595 * column in the database. 1607 * 1608 * @type array|string|int $user_id User ID(s). 1609 * @type array|string $object Corresponds to the 'component' 1610 * column in the database. 1611 * @type array|string $action Corresponds to the 'type' column 1612 * in the database. 1613 * @type array|string|int $primary_id Corresponds to the 'item_id' 1614 * column in the database. 1596 1615 * @type array|string|int $secondary_id Corresponds to the 1597 * 'secondary_item_id' column in the database.1598 * @type int $offsetReturn only those items with an ID greater1599 * than the offset value.1600 * @type string $sinceReturn only those items that have a1601 * date_recorded value greater than a given MySQL-formatted1602 * date.1616 * 'secondary_item_id' column in the database. 1617 * @type int $offset Return only those items with an ID greater 1618 * than the offset value. 1619 * @type string $since Return only those items that have a 1620 * date_recorded value greater than a 1621 * given MySQL-formatted date. 1603 1622 * } 1623 * 1604 1624 * @return string The filter clause, for use in a SQL query. 1605 1625 */ … … 1678 1698 * @since BuddyPress (1.2.0) 1679 1699 * 1680 * @param int The ID of the user whose favorites you're counting. 1681 * @return int A count of the user's favorites. 1700 * @param int $user_id The ID of the user whose favorites you're counting. 1701 * 1702 * @return int $value A count of the user's favorites. 1682 1703 */ 1683 1704 public static function total_favorite_count( $user_id ) { … … 1697 1718 * 1698 1719 * @param string $content The content to filter by. 1720 * 1699 1721 * @return int|bool The ID of the first matching item if found, otherwise false. 1700 1722 */ … … 1711 1733 * 1712 1734 * @param int $user_id The ID of the user whose activity you want to mark hidden. 1713 * @param int 1735 * 1736 * @return mixed 1714 1737 */ 1715 1738 public static function hide_all_for_user( $user_id ) { … … 1739 1762 * @param array $base Array with keys needing to be replaced 1740 1763 * @param array $replacements Array with the replaced keys 1764 * 1741 1765 * @return array 1742 1766 */ -
trunk/src/bp-activity/classes/class-bp-activity-feed.php
r9819 r9833 18 18 * See {@link bp_activity_action_sitewide_feed()} as an example. 19 19 * 20 * Accepted parameters: 21 * id - internal id for the feed; should be alphanumeric only 22 * (required) 23 * title - RSS feed title 24 * link - Relevant link for the RSS feed 25 * description - RSS feed description 26 * ttl - Time-to-live (see inline doc in constructor) 27 * update_period - Part of the syndication module (see inline doc in 28 * constructor for more info) 29 * update_frequency - Part of the syndication module (see inline doc in 30 * constructor for more info) 31 * max - Number of feed items to display 32 * activity_args - Arguments passed to {@link bp_has_activities()} 33 * 20 * @param array $args { 21 * @type string $id Required. Internal id for the feed; should be alphanumeric only. 22 * @type string $title Optional. RSS feed title. 23 * @type string $link Optional. Relevant link for the RSS feed. 24 * @type string $description Optional. RSS feed description. 25 * @type string $ttl Optional. Time-to-live. (see inline doc in constructor) 26 * @type string $update_period Optional. Part of the syndication module. 27 * (see inline doc in constructor for more info) 28 * @type string $update_frequency Optional. Part of the syndication module. 29 * (see inline doc in constructor for more info) 30 * @type string $max Optional. Number of feed items to display. 31 * @type array $activity_args Optional. Arguments passed to {@link bp_has_activities()} 32 * } 34 33 * @since BuddyPress (1.8.0) 35 34 */ 36 35 class BP_Activity_Feed { 36 37 37 /** 38 38 * Holds our custom class properties. … … 50 50 * 51 51 * @param string $key 52 * 53 * @return bool Whether or not data variable exists. 52 54 */ 53 55 public function __isset( $key ) { return isset( $this->data[$key] ); } … … 57 59 * 58 60 * @param string $key 61 * 62 * @return mixed Data in variable if available or null. 59 63 */ 60 64 public function __get( $key ) { return isset( $this->data[$key] ) ? $this->data[$key] : null; } … … 124 128 * @since BuddyPress (1.8.0) 125 129 * 126 * @param BP_Activity_Feed Reference to current instance of activity feed.130 * @param BP_Activity_Feed $this Current instance of activity feed. Passed by reference. 127 131 */ 128 132 do_action_ref_array( 'bp_activity_feed_prefetch', array( &$this ) ); … … 142 146 * @since BuddyPress (1.8.0) 143 147 * 144 * @param BP_Activity_Feed Reference to current instance of activity feed.148 * @param BP_Activity_Feed $this Current instance of activity feed. Passed by reference. 145 149 */ 146 150 do_action_ref_array( 'bp_activity_feed_postfetch', array( &$this ) ); -
trunk/src/bp-activity/classes/class-bp-activity-query.php
r9819 r9833 91 91 * 92 92 * @param string $alias An existing table alias that is compatible with the current query clause. 93 * Default: 'a'. BP_Activity_Activity::get() uses 'a', so we default to that. 93 * Default: 'a'. BP_Activity_Activity::get() uses 'a', so we default to that. 94 * 94 95 * @return string SQL fragment to append to the main WHERE clause. 95 96 */ … … 116 117 * @param array $clause Array of arguments belonging to the clause. 117 118 * @param array $parent_query Parent query to which the clause belongs. 119 * 118 120 * @return array { 119 121 * @type array $where Array of subclauses for the WHERE statement. … … 226 228 * @access protected 227 229 * 228 * @param array $query Clause to check. 230 * @param array $query Clause to check. 231 * 229 232 * @return bool 230 233 */ … … 243 246 * 244 247 * @param string $column The user-supplied column name. 248 * 245 249 * @return string A validated column name value. 246 250 */
Note: See TracChangeset
for help on using the changeset viewer.