/** * Register bundled theme packages. * * Note that since we currently have complete control over bp-themes and * the bp-legacy folders, it's fine to hardcode these here. If at a * later date we need to automate this, an API will need to be built. * * @since 1.7.0 */ public function register_theme_packages() { // Register the default theme compatibility package bp_register_theme_package(array('id' => 'legacy', 'name' => __('BuddyPress Default', 'buddypress'), 'version' => bp_get_version(), 'dir' => trailingslashit($this->themes_dir . '/bp-legacy'), 'url' => trailingslashit($this->themes_url . '/bp-legacy'))); // Register the basic theme stack. This is really dope. bp_register_template_stack('get_stylesheet_directory', 10); bp_register_template_stack('get_template_directory', 12); bp_register_template_stack('bp_get_theme_compat_dir', 14); }
function templatepack_work() { bp_register_theme_package(array('id' => 'templates', 'name' => __('BuddyPress Templates', 'buddypress'), 'version' => bp_get_version(), 'dir' => plugin_dir_path(__FILE__), 'url' => plugin_dir_url(__FILE__))); }