bbp_setup_theme_compat( BBP_Theme_Compat $theme = '' )
Setup the default theme compat theme
Description
Parameters
- $theme
-
(Optional)
Default value: ''
Source
File: bp-forums/core/theme-compat.php
95 96 97 98 99 100 101 102 103 104 105 | function bbp_setup_theme_compat( $theme = '' ) { $bbp = bbpress(); // Make sure theme package is available, set to default if not if ( ! isset( $bbp ->theme_compat->packages[ $theme ] ) || ! is_a ( $bbp ->theme_compat->packages[ $theme ], 'BBP_Theme_Compat' ) ) { $theme = 'default' ; } // Set the active theme compat theme $bbp ->theme_compat->theme = $bbp ->theme_compat->packages[ $theme ]; } |
Changelog
Version | Description |
---|---|
bbPress (r3311) | 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.