BP_Nouveau::includes()
Includes!
Description
Source
File: bp-templates/bp-nouveau/buddypress-functions.php
protected function includes() { require $this->includes_dir . 'functions.php'; require $this->includes_dir . 'classes.php'; require $this->includes_dir . 'template-tags.php'; // Test suite requires the AJAX functions early. if ( function_exists( 'tests_add_filter' ) ) { require $this->includes_dir . 'ajax.php'; // Load AJAX code only on AJAX requests. } else { add_action( 'admin_init', function() { if ( defined( 'DOING_AJAX' ) && true === DOING_AJAX ) { require $this->includes_dir . 'ajax.php'; } }, 0 ); } add_action( 'bp_customize_register', function() { if ( bp_is_root_blog() && current_user_can( 'customize' ) ) { require $this->includes_dir . 'customizer.php'; } }, 0 ); foreach ( bp_core_get_packaged_component_ids() as $component ) { $component_loader = trailingslashit( $this->includes_dir ) . $component . '/loader.php'; if ( ! bp_is_active( $component ) || ! file_exists( $component_loader ) ) { continue; } require( $component_loader ); } if ( bp_is_active( 'activity' ) && bp_is_activity_follow_active() ) { $component_loader = trailingslashit( $this->includes_dir ) . 'follow/loader.php'; if ( file_exists( $component_loader ) ) { require( $component_loader ); } } /** * Fires after all of the BuddyPress Nouveau includes have been loaded. Passed by reference. * * @since BuddyPress 3.0.0 * * @param BP_Nouveau $value Current BP_Nouveau instance. */ do_action_ref_array( 'bp_nouveau_includes', array( &$this ) ); }
Changelog
Version | Description |
---|---|
BuddyPress 3.0.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.