WordPress.org

Ready to get started?Download WordPress

Forums

BuddyPress Group Folders
Make it multisite compatible (2 posts)

  1. Fee
    Member
    Posted 1 year ago #

    Yeah, cool plugin! And it works out of the box :-) Big thanks to you!

    Request: Make it multisite / multinetwork compatible. Yes, some people have multiple buddypress communities in one install. Just change this:
    In class bp_gfold line 122-123 to:

    if ( is_multisite() ){
    	$this->repo_root = WP_CONTENT_DIR.'/'.$this->get_pref('path').'/'.BP_ROOT_BLOG.'/'.$this->get_pref('path');
    	$this->repo_root_url = WP_CONTENT_URL.'/'.$this->get_pref('path').'/'.BP_ROOT_BLOG.'/'.$this->get_pref('path');
        } else {
    	$this->repo_root = WP_CONTENT_DIR.'/'.$this->get_pref('path');
    	$this->repo_root_url = WP_CONTENT_URL.'/'.$this->get_pref('path');
    }

    This works for me :-)

    http://wordpress.org/extend/plugins/buddypress-group-folders/

  2. Fee
    Member
    Posted 1 year ago #

    Sorry, little mistake: there's a trailingslash to much. To be sure it is placed correctly, i did it like this now:

    if ( is_multisite() ){
    	$this->repo_root = trailingslashit(WP_CONTENT_DIR.'/'.$this->get_pref('path')).BP_ROOT_BLOG.'/'.$this->get_pref('path');
    	$this->repo_root_url = trailingslashit(WP_CONTENT_URL.'/'.$this->get_pref('path')).BP_ROOT_BLOG.'/'.$this->get_pref('path');
    } else {
    	$this->repo_root = WP_CONTENT_DIR.'/'.$this->get_pref('path');
    	$this->repo_root_url = WP_CONTENT_URL.'/'.$this->get_pref('path');
    }

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic