WordPress.org

Ready to get started?Download WordPress

Forums

BuddyPress Activity Plus
[resolved] Media disappears in the Wire (8 posts)

  1. minto
    Member
    Posted 1 year ago #

    Hi there + thanks for this Plugin!

    I have implemented the Wire-Solution from Brajesh (found here),
    which works fine for me.

    My issue is, that I can add media via A-plus, it also appears on the users stream, but when the page is refreshed, it has gone!
    On the mainstream of all users it is still there, but not on personal stream!

    Would there be any simple fix for that?

    Regards!

    http://wordpress.org/extend/plugins/buddypress-activity-plus/

  2. Hello there @minto,
    I'm afraid that these 2 plugins are not 100% compatible... and due to their similar nature you might have to custom-code a solution for that. I looked for a solution but coding is not one of my strongest points so I couldn't find where exactly the issue lies.

  3. minto
    Member
    Posted 1 year ago #

    thanks anyway, aristath!

    i got it!

    if anyone is having that same issue, insert one line in class-bpfb-binder.php (around line 273)

    if ($bpfb_code) {
    			$content = @$_POST['content'] . "\n" . $bpfb_code;
    
    			$content = "@" . bp_get_displayed_user_username() . " " . $_POST['content'] . "\n" . $bpfb_code;
    
    			$content = apply_filters('bp_activity_post_update_content', $content);
  4. minto
    Member
    Posted 1 year ago #

    edit:
    due to issues on the own profile (on an update i would mention myself), there needs to be the if/else around:

    if ($bpfb_code) {
    			$content = @$_POST['content'] . "\n" . $bpfb_code;
    
    if (!bp_is_home() && bp_is_member())
    $content = "@" . bp_get_displayed_user_username() . " " . $_POST['content'] . "\n" . $bpfb_code;
     else
     $content = $_POST['content'] . "\n" . $bpfb_code;
    
    			$content = apply_filters('bp_activity_post_update_content', $content);

    so thats it^^

  5. Hello there @minto!

    Thank you for letting us know and sharing this info!
    I'm sure other users will find that useful as well!

  6. mcpeanut
    Member
    Posted 1 year ago #

    hi there minto i am just about to add this feature from brajesh,s tutorial too but before i do it im a little confused as to the problem you solved? does this problem only arrive when using activity plus plugin? if so where which code do i add from above to the class-bpfb-binder.php? and where is this file located? and what line should i put it after exactly? thx

  7. minto
    Member
    Posted 1 year ago #

    hi mc!

    class-bpfb-binder is located in wp-content/plugins/buddypress-activity-plus/lib/

    for me, brajeshs hack worked fine so far (beside one single issue of doubleposting, which passed after sparing his very first modification line out). i had the entrybox on the single-profile, and it worked just fine for any written comments. but with activity-plus it was the case, that all mediapostings just showed up until the next refresh. anyway it was correctly posted (i.e. with videopreview) on the main-activity-stream.

    so get your class-bpfb-binder.php in that location, then go to line 271 forward. in the first example above was added this "$content = "@" . bp_get_displayed_user_username"... forget this line, as seen in example 2, and add instead:

    if (!bp_is_home() && bp_is_member())
    $content = "@" . bp_get_displayed_user_username() . " " . $_POST['content'] . "\n" . $bpfb_code;
    else
    $content = $_POST['content'] . "\n" . $bpfb_code;

    works on 3.5.1/1.7.2

    hope that helps :)

  8. Mike
    WPMU DEV Support Staff
    Posted 9 months ago #

    Thanks for posting and clarifying!

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic

Tags

No tags yet.