Changeset 10012 for trunk/src/bp-core/bp-core-attachments.php
- Timestamp:
- 07/12/2015 12:49:36 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-core/bp-core-attachments.php
r9860 r10012 19 19 * @since BuddyPress (2.3.0) 20 20 * 21 * @return bool True if WordPress is 3.9+, false otherwise 21 * @return bool True if WordPress is 3.9+, false otherwise. 22 22 */ 23 23 function bp_attachments_is_wp_version_supported() { … … 26 26 27 27 /** 28 * Get the BuddyPress Plupload settings 29 * 30 * @since BuddyPress (2.3.0) 31 * 32 * @return array list of BuddyPress Plupload settings 28 * Get the BuddyPress Plupload settings. 29 * 30 * @since BuddyPress (2.3.0) 31 * 32 * @return array list of BuddyPress Plupload settings. 33 33 */ 34 34 function bp_attachments_get_plupload_default_settings() { … … 84 84 85 85 /** 86 * Builds localization strings for the BuddyPress Uploader scripts 87 * 88 * @since BuddyPress (2.3.0) 89 * 90 * @return array Plupload default localization strings 86 * Builds localization strings for the BuddyPress Uploader scripts. 87 * 88 * @since BuddyPress (2.3.0) 89 * 90 * @return array Plupload default localization strings. 91 91 */ 92 92 function bp_attachments_get_plupload_l10n() { … … 120 120 121 121 /** 122 * Enqueues the script needed for the Uploader UI 122 * Enqueues the script needed for the Uploader UI. 123 123 * 124 124 * @see BP_Attachment::script_data() && BP_Attachment_Avatar::script_data() for examples showing how 125 * to set specific script data 126 * 127 * @since BuddyPress (2.3.0) 128 * 129 * @param string $class name of the class extending BP_Attachment (eg: BP_Attachment_Avatar) 125 * to set specific script data. 126 * 127 * @since BuddyPress (2.3.0) 128 * 129 * @param string $class name of the class extending BP_Attachment (eg: BP_Attachment_Avatar). 130 * 131 * @return null|WP_Error 130 132 */ 131 133 function bp_attachments_enqueue_scripts( $class = '' ) { … … 240 242 241 243 /** 242 * Use this filter to add a navigation to a custom tool to set the object's avatar 244 * Use this filter to add a navigation to a custom tool to set the object's avatar. 243 245 * 244 246 * @since BuddyPress (2.3.0) … … 246 248 * @param array $avatar_nav An associative array of available nav items where each item is an array organized this way: 247 249 * $avatar_nav[ $nav_item_id ] { 248 * @type string $nav_item_id the nav item id in lower case without special characters or space249 * @type string $caption the name of the item nav that will be displayed in the nav250 * @type int $order An integer to specify the priority of the item nav, choose one 251 * between 1 and 99 to be after the uploader nav item and before the delete nav item 252 * @type int $hide if set to 1 the item nav will be hidden253 * (only used for the delete nav item) 250 * @type string $nav_item_id The nav item id in lower case without special characters or space. 251 * @type string $caption The name of the item nav that will be displayed in the nav. 252 * @type int $order An integer to specify the priority of the item nav, choose one. 253 * between 1 and 99 to be after the uploader nav item and before the delete nav item. 254 * @type int $hide If set to 1 the item nav will be hidden 255 * (only used for the delete nav item). 254 256 * } 255 257 * @param string $object the object the avatar belongs to (eg: user or group) … … 298 300 * to avoid the scripts to be loaded more than once. 299 301 * 300 * @since BuddyPress 2.3.0302 * @since BuddyPress (2.3.0) 301 303 */ 302 304 do_action( 'bp_attachments_enqueue_scripts' ); … … 304 306 305 307 /** 306 * Check the current user's capability to edit an avatar for a given object 307 * 308 * @since BuddyPress (2.3.0) 309 * 310 * @param string $capability the capability to check 311 * @param array $args an array containing the item_id and the object to check 308 * Check the current user's capability to edit an avatar for a given object. 309 * 310 * @since BuddyPress (2.3.0) 311 * 312 * @param string $capability The capability to check. 313 * @param array $args An array containing the item_id and the object to check. 314 * 315 * @return bool 312 316 */ 313 317 function bp_attachments_current_user_can( $capability, $args = array() ) { … … 351 355 * @since BuddyPress (2.3.0) 352 356 * 353 * @param bool true for a success, false otherwise354 * @param bool true if the Plupload runtime used is html4, false otherwise.355 * @param mixed $data Data to encode as JSON, then print and die.357 * @param bool $success True for a success, false otherwise. 358 * @param bool $is_html4 True if the Plupload runtime used is html4, false otherwise. 359 * @param mixed $data Data to encode as JSON, then print and die. 356 360 */ 357 361 function bp_attachments_json_response( $success, $is_html4 = false, $data = null ) { … … 381 385 * Get an Attachment template part. 382 386 * 383 * @since BuddyPress (2.3.0) 384 * 385 * @param string Template part slug. eg 'uploader' for 'uploader.php'. 387 * @since BuddyPress (2.3.0) 388 * 389 * @param string $slug Template part slug. eg 'uploader' for 'uploader.php'. 390 * 391 * @return bool 386 392 */ 387 393 function bp_attachments_get_template_part( $slug ) {
Note: See TracChangeset
for help on using the changeset viewer.