function bb_get_current_theme_data($property = 'all')
{
    if (!$property) {
        $property = 'all';
    }
    $directory = bb_get_active_theme_directory();
    $stylesheet = $directory . 'style.css';
    if (file_exists($stylesheet)) {
        $data = bb_get_theme_data($stylesheet);
    }
    if ($property == 'all') {
        return $data;
    } elseif (isset($data[$property])) {
        return $data[$property];
    } else {
        return false;
    }
}
function bb_get_stylesheet_uri($stylesheet = '')
{
    if ('rtl' == $stylesheet) {
        $css_file = 'style-rtl.css';
    } else {
        $css_file = 'style.css';
    }
    $active_theme = bb_get_active_theme_directory();
    if (file_exists($active_theme . $css_file)) {
        $r = bb_get_active_theme_uri() . $css_file;
    } else {
        $r = BB_DEFAULT_THEME_URL . $css_file;
    }
    return apply_filters('bb_get_stylesheet_uri', $r, $stylesheet);
}
Ejemplo n.º 3
0
function bb_get_active_theme_folder()
{
    bb_log_deprecated('function', __FUNCTION__, 'bb_get_active_theme_directory');
    return apply_filters('bb_get_active_theme_folder', bb_get_active_theme_directory());
}
Ejemplo n.º 4
0
        }
    }
    unset($deprecated_constants, $old, $new);
    /**
     * Load deprecated functions
     */
    require_once BB_PATH . BB_INC . 'functions.bb-deprecated.php';
    /**
     * Old cache global object for backwards compatibility
     */
    $bb_cache = new BB_Cache();
}
/**
 * Load active template functions.php file
 */
$template_functions_include = bb_get_active_theme_directory() . 'functions.php';
if (file_exists($template_functions_include)) {
    require_once $template_functions_include;
}
unset($template_functions_include);
/**
 * Load Plugins
 */
// Skip plugin loading in "safe" mode
if ($bb->plugin_locations && (!isset($bb->safemode) || $bb->safemode !== true)) {
    // Autoloaded "underscore" plugins
    foreach ($bb->plugin_locations as $_name => $_data) {
        foreach (bb_glob($_data['dir'] . '_*.php') as $_plugin) {
            require_once $_plugin;
        }
        unset($_plugin);