BuddyDev

Search

[Resolved] Multiblog Mode – Member Type Synchronization

  • Participant
    Level: Enlightened
    Posts: 44
    teacherpete on #47926

    Hi Brajesh,

    I’ve just read your fantastic post here: https://buddydev.com/docs/buddypress-member-types-pro/multisite-buddypress-multiblog-mode-member-type-synchronization-across-blogs/

    What do I need to change in this to get it working with my multiblog? Also, I really hope this will work with BuddyBoss 😁

    I need to share member types across every site in the multiblog. Your code on the site is like this, but I’m not sure what I need to change to make it work on my BuddyBoss site.

    Thanks for your help! Code below.

    /**
    * Fix the synchronization of the member types across all blogs on multisite, multiblog mode.
    */
    function buddydev_fix_multiblog_taxonomy_site_id( $blog_id ) {
    $blog_id = BLOG_ID_CURRENT_SITE; // Change it.
    // Put the blog id you want all the member type associations with user to be saved
    // If you have existing association, you may want to use that
    return $blog_id;
    }
    add_filter( ‘bp_get_taxonomy_term_site_id’, ‘buddydev_fix_multiblog_taxonomy_site_id’ );

  • Participant
    Level: Enlightened
    Posts: 44
    teacherpete on #47927

    Hi Brajesh,

    I’ve just read your fantastic post here: https://buddydev.com/docs/buddypress-member-types-pro/multisite-buddypress-multiblog-mode-member-type-synchronization-across-blogs/

    Please could you help me to get it working with my multiblog on BuddyBoss? I need member types to be shared across all sites.

    Thanks for your help! Your code below:

    /**
    * Fix the synchronization of the member types across all blogs on multisite, multiblog mode.
    */
    function buddydev_fix_multiblog_taxonomy_site_id( $blog_id ) {
    $blog_id = BLOG_ID_CURRENT_SITE; // Change it.
    // Put the blog id you want all the member type associations with user to be saved
    // If you have existing association, you may want to use that
    return $blog_id;
    }
    add_filter( ‘bp_get_taxonomy_term_site_id’, ‘buddydev_fix_multiblog_taxonomy_site_id’ );

  • Keymaster
    (BuddyDev Team)
    Posts: 22498
    Brajesh Singh on #47949

    Hi Peter,
    Thank you.
    It’s good to know that it worked:)

    Regards
    Brajesh

  • Keymaster
    (BuddyDev Team)
    Posts: 22498
    Brajesh Singh on #47950

    Oops, replied to this post instead of your other post.

    Please ignore the previous reply.

  • Keymaster
    (BuddyDev Team)
    Posts: 22498
    Brajesh Singh on #47951

    Hi Peter,
    Can you please tell me on which site did you create the member types? Was it your main site? If yes, you can replace
    BLOG_ID_CURRENT_SITE with 1. Otherwise, Please use the blog id on which you have created the member types.

    PS:- BuddyPress and BuddyBoss both uses taxonomy terms as member type but they differ on the interface used for creation of the member types. BuddyBoss uses a post type for the creation interface while BuddyPress utilizes the taxonomy screen. It should not affect fetching of the terms(unless BuddyBoss fetches from post type instead of terms).

    Regards
    Brajesh

  • Participant
    Level: Enlightened
    Posts: 44
    teacherpete on #47955

    Hi Brajesh!

    Thanks so much for your answer.

    I may have a further question in regards to Multiblog Mode that may perhaps require perhaps some custom coding.

    I want to share the entire community across the multisite. So one community, and two sites (in a multisite/multiblog configuration). I would like our users to be shared across one community, and accessible from both sites. One community = two sites.

    I would like shared users, shared media, shared user profile types, shared group types, etc. across all networks. I need the user based to be shared, so that the same tables are used for each instance of BP. This means the Groups, Forums, Profiles, etc will be shared and accessible via both the main site and the subsite.

    Please can you help me to code this? I feel like I just need to somehow change the database tables prefixes.

    The reason I am doing this is because I have a multilingual site (which is the primary reason to activate multiblog). One website will be primarily in Chinese. The other will be primarily in English. The teacher can interact with the community, post status updates from the English site with teacher-focused UI and menu structure. The Chinese will then be able to respond and engage from the Chinese-facing site, which is optimized design and SEO for the Chinese parents and students.

    I have a few questions:

    1. If I buy the support for $99, then would you be able to help me set it up so that the multiblog network shares the same database tables for the community?
    2. Would 3rd party plugins act the same as they usually would in a multisite network, or would it cause problems for all third-party plugins after syncing the BP user base together? For example: right now, every user on my multisite network is given a unique URL code with AffiliateWP (which they can share with other potential customers). Is this kind of data affected by syncing the user base of site 1 and site 2? Will plugins outside of BuddyBoss function like they usually do in multisite?

    Please confirm and let me know your thoughts on whether I should go ahead with this setup. But hopefully once the user base is synced, the other plugins should be configured the same way that they would be on regular multisite, right? (i.e. the same as they would on multisite without multiblog).

    Thanks so much, and looking forward to hearing your wisdom on this.

    Kind regards,
    Peter

  • Participant
    Level: Enlightened
    Posts: 44
    teacherpete on #47956

    And to answer your first question – everything was built in BuddyBoss! I should have said. I used the term interchangeably but probably should have clarified. Everything was created on a regular multisite (ID = 1).

    I want it to draw everything, really, from this site. Whilst not going too deep or complex on coding, so that I can simply “have a window” into the community from either side. With a frame around that window, which is English, for teachers in the UK or USA. And then a frame around blog ID = 1 (the community site), which has Chinese language, and a UI for Chinese users.

    Two sites, one user base. Great UX for both sides. 🙂

    Please let me know your thoughts. I have seen some people say it’s as simple as adding this to wp-config:

    define ( ‘BP_ROOT_BLOG’, 1 );

    Is that true?

  • Participant
    Level: Enlightened
    Posts: 44
    teacherpete on #47957

    (Nope to that last piece of code – ‘BP_ROOT_BLOG’) 😣

    I’m sure it must be easier than I think to have 1 user base with multiblog active. 🙂

    I’ll wait for your news, as the professional. ☝️

    Kind regards,
    Peter

  • Keymaster
    (BuddyDev Team)
    Posts: 22498
    Brajesh Singh on #47963

    HI Peter,
    Thank you for the replies.

    1. The Multi Network plugin is not suitable for your need. It allows you to have separate social networks on a single multisite and not the other way.

    2. The support package for multi network includes troubleshooting if the specified featured do not work. It does not include any custom coding requirement.

    Even though I understand what you are looking is important, there is no proper solution. The media/contents which use post types are specific to blog where they were created. Even though the creation blog can be changed using switch_to_blog(), It needs support by all the plugins you use.

    So, I do not see any simple solution.

    Regards
    Bajesh

  • Participant
    Level: Enlightened
    Posts: 44
    teacherpete on #47990

    Hi Brajesh,

    Thank you so much for your reply.

    1 and 2. Firstly, thanks so much for confirming. This is very useful to know.

    Also, I appreciate that you’ve let me know about the complexity of this kind of setup. It sounds like it would cause a real issue to be using multiblog. So thank you for being honest about the difficulty associated with this kind of setup.

    It sounds like every plugin would need to be supported and custom edited, which is far too difficult to manage and maintain! Far better off dealing with standard multisite.

    Again, I really appreciate your honesty here – as it steers me in the right direction. 🙏

    Regards,
    Peter

You must be logged in to reply to this topic.

This topic is: resolved