Skip to:
Content
Pages
Categories
Search
Top
Bottom

Missing – else return $action


  • DamnDramaQueen
    Participant

    @damndramaqueen

    Hi bbPress,

    I am using bbPress Version 2.6.1.1

    I put this ( else return $action; ) very end/bottom of that page, also I realized there’s NO ?> at the end, so I added this ?> in and getting a WHITE PAGE? Can you tell me what am I doing wrong?

    Anyhow, it say put the ” else return $action; ” at the end of the function? There are many functions, but which one or line btw? Help!

    Please click this link for the info https://bbpress.trac.wordpress.org/ticket/2779

    Please advise help.

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

  • Robin W
    Moderator

    @robin-w

    the other trac ticket it refers to tells you where to put it

    https://bbpress.trac.wordpress.org/changeset/5512

    but you’d need to check whether 2.6 has already included that


    DamnDramaQueen
    Participant

    @damndramaqueen

    Hi Robin,

    In the dashboard page it displayed this message that how i find out about it. So appearently 2.6.1.1 doesn’t have it, otherwise this message link wouldn’t displayed on admin page?

    Attention: bbpress-bug: If you use bbpress < 2.6 please apply the changes described there: https://bbpress.trac.wordpress.org/ticket/2779 to get the notifications working

    I even opened the notifications.php in notepad and even did a search for “else return $action;” , looked from top to bottom many times, no phase like that?

    Not sure if I have to change the whole bunch of code or what from the 5512 link above.
    This is a another language I have no idea what I’m suppose to do?

    If all I need is to put this “else return $action;” , please show me how and where to put it? I put very bottom “else return $action;” ?> and getting a white page? Please help..

    Show how bbPress 2.6.1.1 don’t have it? Perhaps is there’s a page I can go download this notifications.php ?

    Please help,help. Thanks


    Robin W
    Moderator

    @robin-w

    The code is included in 2.6 alpha

    /includes/extend/buddypress/notifications.php

    lines 43-45

    // Bail if not the notification action we are looking for
    	if ( 'bbp_new_reply' !== $action ) {
    		return $action;
    	}

    DamnDramaQueen
    Participant

    @damndramaqueen

    Hi Robin,

    I followed your instruction. No white page after uploaded that’s all good… Not sure this a default global message in general or what? That Attention message still exist above the admin page?

    Anyhow, I pasted that phase on line 43 that is after this function.

    function bbp_format_buddypress_notifications( $action, $item_id, $secondary_item_id, $total_items, $format = ‘string’ ) {

    // Bail if not the notification action we are looking for – THIS IS FROM ADMIN BUG MESSAGE , bbpress.org/forums/topic/missing-else-return-action/#post-176758
    if ( ‘bbp_new_reply’ !== $action ) {
    return $action;
    }

    // New reply notifications
    if ( ‘bbp_new_reply’ === $action )

    Also I’m not sure am I suppose to do this or not? I don’t understand php, but what I don’t see is this ?> at the END of the php? I see every other php do have it!

    So I added this ?> to close it. I hope is right?

    Please advise help if this Ok? Thanks


    Robin W
    Moderator

    @robin-w

    ok

    If you are using 2.6.1 then the fix is in there. The message is from the buddypress plugin that doesn’t know what version of bbpress you are using, so just puts that message up !

    Do you actually have an issue other than seeing this message?

    if not then ignore it

    If so then come back


    DamnDramaQueen
    Participant

    @damndramaqueen

    Hi Robin,

    You has been a big time help to fix my file 🙂 No white page and functioning good.

    Ok, I will ignore that message then. Just never like any RED words or phase LOL

    I will come back for other help another day I’m sure 🙂

    Thank you for your wonderful help big time! You saved my life 🙂

    Have a wonderful day!


    Robin W
    Moderator

    @robin-w

    great – glad you are fixed !

Viewing 7 replies - 1 through 7 (of 7 total)
  • You must be logged in to reply to this topic.
Skip to toolbar