forked from boonebgorges/buddypress-docs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathloader.php
38 lines (32 loc) · 970 Bytes
/
loader.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?php
/*
Plugin Name: BuddyPress Docs
Plugin URI: http://github.com/boonebgorges/buddypress-docs
Description: Adds collaborative Docs to BuddyPress
Version: 1.9.1
Author: Boone B Gorges
Author URI: http://boone.gorg.es
Licence: GPLv3
*/
/*
It's on like Donkey Kong
*/
define( 'BP_DOCS_VERSION', '1.9.1' );
// BuddyPress Docs introduces a lot of overhead. Unless otherwise specified,
// don't load the plugin on subsites of an MS install
if ( !defined( 'BP_DOCS_LOAD_ON_NON_ROOT_BLOG' ) )
define( 'BP_DOCS_LOAD_ON_NON_ROOT_BLOG', false );
/**
* Loads BP Docs files only if BuddyPress is present
*
* @package BuddyPress Docs
* @since 1.0-beta
*/
function bp_docs_init() {
global $bp_docs, $wpdb;
if ( is_multisite() && BP_ROOT_BLOG != $wpdb->blogid && ( !BP_DOCS_LOAD_ON_NON_ROOT_BLOG ) )
return;
require( dirname( __FILE__ ) . '/bp-docs.php' );
$bp_docs = new BP_Docs;
}
add_action( 'bp_include', 'bp_docs_init' );