Changeset 10021
- Timestamp:
- 07/20/2015 03:41:29 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-groups/classes/class-bp-group-extension.php
r9997 r10021 335 335 * 336 336 * @since BuddyPress (1.8.0) 337 * @since BuddyPress (2.1.0) Added 'access' and 'show_tab' arguments 338 * to $args.337 * @since BuddyPress (2.1.0) Added 'access' and 'show_tab' arguments to `$args`. 338 * 339 339 * @param array $args { 340 340 * Array of initialization arguments. 341 * @type string $slug Unique, URL-safe identifier for your 342 * extension. 343 * @type string $name Translatable name for your extension. Used to 344 * populate navigation items. 345 * @type string $visibility Optional. Set to 'public' for your 346 * extension (the main tab as well as the widget) to be 347 * available to anyone who can access the group; set to 348 * 'private' otherwise. Default: 'public'. 349 * @type int $nav_item_ Position Optional. Location of the nav item 350 * in the tab list. Default: 81. 351 * @type bool $enable_nav_item Optional. Whether the extension's tab should be 352 * accessible to anyone who can view the group. 353 * Default: true. 354 * @type string $nav_item_name Optional. The translatable text you want to appear 355 * in the nav tab. Default: the value of $name. 356 * @type string $display_hook Optional. The WordPress action that 357 * the widget_display() method is hooked to. 358 * Default: 'groups_custom_group_boxes'. 359 * @type string $template_file Optional. Theme-relative path to the template file 360 * BP should use to load the content of your main 361 * extension tab. Default: 'groups/single/plugins.php'. 362 * @type array $screens A multi-dimensional array of configuration 363 * information for the extension screens. See docblock of 364 * {@link BP_Group_Extension} for more details. 365 * @type string|array $access Which users can visit the plugin's tab. 366 * Possible values: 'anyone', 'loggedin', 'member', 367 * 'mod', 'admin' or 'noone'. ('member', 'mod', 'admin' 368 * refer to user's role in group.) Note that 'mod' targets only 369 * group moderators. If you want to allow access to group 370 * moderators and admins, specify `array( 'mod', 'admin' )`. 371 * Defaults to 'anyone' for public groups and 'member' for 372 * private groups. 373 * @type string|array $show_tab Which users can see the plugin's navigation tab. 374 * Possible values: 'anyone', 'loggedin', 'member', 375 * 'mod', 'admin' or 'noone'. ('member', 'mod', 'admin' 376 * refer to user's role in group.) Note that 'mod' targets only 377 * group moderators. If you want to show the tab to group 378 * moderators and admins, specify `array( 'mod', 'admin' )`. 379 * Defaults to 'anyone' for public groups and 'member' for 380 * private groups. 341 * @type string $slug Unique, URL-safe identifier for your extension. 342 * @type string $name Translatable name for your extension. Used to populate 343 * navigation items. 344 * @type string $visibility Optional. Set to 'public' for your extension (the main tab as well 345 * as the widget) to be available to anyone who can access the group; 346 * set to 'private' otherwise. Default: 'public'. 347 * @type int $nav_item_position Optional. Location of the nav item in the tab list. 348 * Default: 81. 349 * @type bool $enable_nav_item Optional. Whether the extension's tab should be accessible to 350 * anyone who can view the group. Default: true. 351 * @type string $nav_item_name Optional. The translatable text you want to appear in the nav tab. 352 * Default: the value of `$name`. 353 * @type string $display_hook Optional. The WordPress action that the widget_display() method is 354 * hooked to. Default: 'groups_custom_group_boxes'. 355 * @type string $template_file Optional. Theme-relative path to the template file BP should use 356 * to load the content of your main extension tab. 357 * Default: 'groups/single/plugins.php'. 358 * @type array $screens A multi-dimensional array of configuration information for the 359 * extension screens. See docblock of {@link BP_Group_Extension} 360 * for more details. 361 * @type string|array $access Which users can visit the plugin's tab. Possible values: 'anyone', 362 * 'loggedin', 'member', 'mod', 'admin' or 'noone'. ('member', 'mod', 363 * 'admin' refer to user's role in group.) Note that 'mod' targets 364 * only group moderators. If you want to allow access to group moderators 365 * and admins, specify `array( 'mod', 'admin' )`. Defaults to 'anyone' 366 * for public groups and 'member' for private groups. 367 * @type string|array $show_tab Which users can see the plugin's navigation tab. Possible values: 368 * 'anyone', 'loggedin', 'member', 'mod', 'admin' or 'noone'. 369 * ('member', 'mod', 'admin' refer to user's role in group.) Note 370 * that 'mod' targets only group moderators. If you want to show the 371 * tab to group moderators and admins, specify 372 * `array( 'mod', 'admin' )`. Defaults to 'anyone' for public groups 373 * and 'member' for private groups. 381 374 * } 382 375 */
Note: See TracChangeset
for help on using the changeset viewer.