Skip to:
Content
Pages
Categories
Search
Top
Bottom

Forum Replies Created

Viewing 7 replies - 1 through 7 (of 7 total)

  • SFMichael
    Participant

    @sfmichael

    This is an old thread however I wanted to accomplish what you have asked and have got it to work.

    What i think happens is when bp_signup_validate is called triggering your validation function, the error should be added to an errors array. This will only be displayed when you call
    in register.php

    You code is right you just need to add:

    Hope this makes sense or is right 😀


    SFMichael
    Participant

    @sfmichael

    When i output $signup i get an array within ‘WP_Error Object’

    That only happened because i was simply refreshing the activation page

    other wise when i print signup i get one.


    SFMichael
    Participant

    @sfmichael

    First function adds code to meta in wp-signups works fine.

    Second function should get this meta which is does however i cant access anything inside it using the likes of $signup[‘meta’] or $signup[‘$user_id’]

    add_filter( 'bp_signup_usermeta', 'custom_add_signup_meta' );

    function custom_add_signup_meta ($meta)
    {
    // create an array of custom meta fields
    $meta['user_blogs'] = $_POST['blogs'];

    if($meta != null)
    {
    return $meta;
    }

    }

    add_filter( 'bp_core_activate_account', 'add_user_to_blogs');

    function add_user_to_blogs($signup)
    {
    global $bp, $wpdb;
    $role = 'bbp_participant';

    echo 'ALL = '.print_r($signup).'';

    foreach ($signup['meta']['user_blogs'] as $key => $value )
    {
    //Stuff
    }

    }

    Any ideas?

    When i output $signup i get an array within ‘WP_Error Object’


    SFMichael
    Participant

    @sfmichael

    Got it, Its not new_forum_post, it was bbp_reply_create


    SFMichael
    Participant

    @sfmichael

    So if i use bbPress, in theory i could create a forum for each sub site then use something similar to the code you found to pull them into one page.


    SFMichael
    Participant

    @sfmichael

    Thanks again I will give this ago and post back with results.


    SFMichael
    Participant

    @sfmichael

    Thanks for your reply, As far as this project goes yes, multisite is essential.

    Oh, I assumed buddypress worked across them all as it is network activated. I also thought bbpress worked with buddypress therefore also worked across the network.

Viewing 7 replies - 1 through 7 (of 7 total)
Skip to toolbar