[ Index ]

PHP Cross Reference of BuddyPress

title

Body

[close]

/src/bp-core/ -> bp-core-options.php (summary)

BuddyPress Options.

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

Defines 25 functions

  bp_get_default_options()
  bp_add_options()
  bp_delete_options()
  bp_setup_option_filters()
  bp_pre_get_option()
  bp_get_option()
  bp_add_option()
  bp_update_option()
  bp_delete_option()
  bp_core_activate_site_options()
  bp_core_get_root_options()
  bp_core_get_root_option()
  bp_disable_profile_sync()
  bp_hide_loggedout_adminbar()
  bp_disable_avatar_uploads()
  bp_disable_cover_image_uploads()
  bp_disable_group_avatar_uploads()
  bp_disable_group_cover_image_uploads()
  bp_disable_account_deletion()
  bp_disable_blogforum_comments()
  bp_restrict_group_creation()
  bp_force_buddybar()
  bp_is_akismet_active()
  bp_is_activity_heartbeat_active()
  bp_get_theme_package_id()

Functions
Functions that are not part of a class:

bp_get_default_options()   X-Ref
Get the default site options and their values.

Default values should not be set by calls to `get_option()` or `get_site_option()` due to
these causing load order problems with `bp_core_clear_root_options_cache()`; see #BP7227.

since: 1.6.0
return: array Filtered option names and values.

bp_add_options()   X-Ref
Add default options when BuddyPress is first activated.

Only called once when BuddyPress is activated.
Non-destructive, so existing settings will not be overridden.

since: 1.6.0

bp_delete_options()   X-Ref
Delete default options.

Hooked to bp_uninstall, it is only called once when BuddyPress is uninstalled.
This is destructive, so existing settings will be destroyed.

Currently unused.

since: 1.6.0

bp_setup_option_filters()   X-Ref
Add filters to each BP option, allowing them to be overloaded from inside the $bp->options array.

since: 1.6.0

bp_pre_get_option( $value = false )   X-Ref
Filter default options and allow them to be overloaded from inside the $bp->options array.

since: 1.6.0
return: mixed False if not overloaded, mixed if set.
param: bool $value Optional. Default value false.

bp_get_option( $option_name, $default = '' )   X-Ref
Retrieve an option.

This is a wrapper for {@link get_blog_option()}, which in turn stores settings data
(such as bp-pages) on the appropriate blog, given your current setup.

The 'bp_get_option' filter is primarily for backward-compatibility.

since: 1.5.0
return: mixed The value for the option.
param: string $option_name The option to be retrieved.
param: string $default     Optional. Default value to be returned if the option

bp_add_option( $option_name, $value )   X-Ref
Add an option.

This is a wrapper for {@link add_blog_option()}, which in turn stores
settings data on the appropriate blog, given your current setup.

since: 2.0.0
return: bool True on success, false on failure.
param: string $option_name The option key to be set.
param: mixed  $value       The value to be set.

bp_update_option( $option_name, $value )   X-Ref
Save an option.

This is a wrapper for {@link update_blog_option()}, which in turn stores
settings data (such as bp-pages) on the appropriate blog, given your current
setup.

since: 1.5.0
return: bool True on success, false on failure.
param: string $option_name The option key to be set.
param: mixed  $value       The value to be set.

bp_delete_option( $option_name )   X-Ref
Delete an option.

This is a wrapper for {@link delete_blog_option()}, which in turn deletes
settings data (such as bp-pages) on the appropriate blog, given your current
setup.

since: 1.5.0
return: bool True on success, false on failure.
param: string $option_name The option key to be deleted.

bp_core_activate_site_options( $keys = array()   X-Ref
Copy BP options from a single site to multisite config.

Run when switching from single to multisite and we need to copy blog options
to site options.

This function is no longer used.

since: 1.2.4
return: bool
param: array $keys Array of site options.

bp_core_get_root_options()   X-Ref
Fetch global BP options.

BuddyPress uses common options to store configuration settings. Many of these
settings are needed at run time. Instead of fetching them all and adding many
initial queries to each page load, let's fetch them all in one go.

since: 1.5.0
return: array $root_blog_options_meta List of options.

bp_core_get_root_option( $option )   X-Ref
Get a root option.

"Root options" are those that apply across an entire installation, and are fetched only a single
time during a pageload and stored in `buddypress()->site_options` to prevent future lookups.
See {@see bp_core_get_root_options()}.

since: 2.3.0
return: mixed Value, if found.
param: string $option Name of the option key.

bp_disable_profile_sync( $default = false )   X-Ref
Is profile syncing disabled?

since: 1.6.0
return: bool True if profile sync is enabled, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_hide_loggedout_adminbar( $default = true )   X-Ref
Is the Toolbar hidden for logged out users?

since: 1.6.0
return: bool True if the admin bar should be hidden for logged-out users,
param: bool $default Optional. Fallback value if not found in the database.

bp_disable_avatar_uploads( $default = true )   X-Ref
Are members able to upload their own avatars?

since: 1.6.0
return: bool True if avatar uploads are disabled, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_disable_cover_image_uploads( $default = false )   X-Ref
Are members able to upload their own cover images?

since: 2.4.0
return: bool True if cover image uploads are disabled, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_disable_group_avatar_uploads( $default = null )   X-Ref
Are group avatars disabled?

For backward compatibility, this option falls back on the value of 'bp-disable-avatar-uploads' when no value is
found in the database.

since: 2.3.0
return: bool True if group avatar uploads are disabled, otherwise false.
param: bool|null $default Optional. Fallback value if not found in the database.

bp_disable_group_cover_image_uploads( $default = false )   X-Ref
Are group cover images disabled?

since: 2.4.0
return: bool True if group cover image uploads are disabled, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_disable_account_deletion( $default = false )   X-Ref
Are members able to delete their own accounts?

since: 1.6.0
return: bool True if users are able to delete their own accounts, otherwise
param: bool $default Optional. Fallback value if not found in the database.

bp_disable_blogforum_comments( $default = false )   X-Ref
Are post/comment activity stream comments disabled?

since: 1.6.0
return: bool True if activity comments are disabled for blog and forum
param: bool $default Optional. Fallback value if not found in the database.

bp_restrict_group_creation( $default = true )   X-Ref
Is group creation turned off?

since: 1.6.0
return: bool True if group creation is restricted, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_force_buddybar( $default = true )   X-Ref
Should the old BuddyBar be forced in place of the WP admin bar?

since: 1.6.0
return: bool True if the BuddyBar should be forced on, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_is_akismet_active( $default = true )   X-Ref
Check whether Akismet is enabled.

since: 1.6.0
return: bool True if Akismet is enabled, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_is_activity_heartbeat_active( $default = true )   X-Ref
Check whether Activity Heartbeat refresh is enabled.

since: 2.0.0
return: bool True if Heartbeat refresh is enabled, otherwise false.
param: bool $default Optional. Fallback value if not found in the database.

bp_get_theme_package_id( $default = 'legacy' )   X-Ref
Get the current theme package ID.

since: 1.7.0
return: string ID of the theme package.
param: string $default Optional. Fallback value if not found in the database.



Generated: Sat Sep 21 01:01:46 2019 Cross-referenced by PHPXref 0.7.1