bp_setup_option_filters()
Add filters to each BP option, allowing them to be overloaded from inside the $bp->options array.
Description Description
Source Source
File: bp-core/bp-core-options.php
function bp_setup_option_filters() {
// Get the default options and values.
$options = bp_get_default_options();
// Add filters to each BuddyPress option.
foreach ( array_keys( $options ) as $key ) {
add_filter( 'pre_option_' . $key, 'bp_pre_get_option' );
}
/**
* Fires after the addition of filters to each BuddyPress option.
*
* Allows previously activated plugins to append their own options.
*
* @since 1.6.0
*/
do_action( 'bp_setup_option_filters' );
}
Changelog Changelog
| Version | Description |
|---|---|
| 1.6.0 | Introduced. |