bb_get_theme_uri

The BuddyPress bb get theme uri function.

Description

bb_get_theme_uri( (bool) $theme = false ); 

Parameters (1)

0. $theme — Optional. (bool) => false
The theme.

Usage

  1. if ( !function_exists( 'bb_get_theme_uri' ) ) { 
  2. require_once ABSPATH . PLUGINDIR . 'buddypress/bp-forums/bbpress/bb-includes/functions.bb-template.php'; 
  3.  
  4. // The theme. 
  5. $theme = false; 
  6.  
  7. // NOTICE! Understand what this does before running. 
  8. $result = bb_get_theme_uri($theme); 
  9.  

Defined (1)

The function is defined in the following location(s).

/bp-forums/bbpress/bb-includes/functions.bb-template.php  
  1. function bb_get_theme_uri( $theme = false ) 
  2. global $bb; 
  3. if ( preg_match( '/^([a-z0-9_-]+)#([a-z0-9_-]+)$/i', $theme, $_matches ) ) { 
  4. $theme_uri = $bb->theme_locations[$_matches[1]]['url'] . $_matches[2] . '/'; 
  5. } else { 
  6. $theme_uri = $bb->theme_locations['core']['url']; 
  7. return apply_filters( 'bb_get_theme_uri', $theme_uri, $theme );