This topic has 4 replies, 2 voices, and was last updated 6 years by Radu.

  • Author
  • #194967
     TheDream18
    Participant

    Hi,

    I added modify header $profile_menu as attachment

    <pre>

     

    if ( bp_is_active( ‘logout’ ) )

    { $profile_menu[‘logout’] = ‘<li><a href=”‘. ‘logout/”>’ . __( “LogOut”, “buddypress” ) . ‘</a>

    </li>’; }

    </pre>

    Can you help me correct it?

    When i click “Logout button” It given a blank page “domain.com/logout” instead of give user logout and back to homepage.

    Thanks

    Attachments:
    You must be logged in to view attached files.
    #195025
     Radu
    Moderator

    Hi,

    I think you should add wp_logout_url( ‘/url-page-to-be-redirected’ ); while you generate the logout link

    Cheers
    R

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #195089
     TheDream18
    Participant

    Hi, i changed code to:

    COPY CODE
    
    if ( bp_is_active( 'logout' ) ) {
    									$profile_menu['logout'] = 
    									'<li>
    									<a href="'
    									. wp_logout_url('/url-page-to-be-redirected' )
    									. __( "LogOut", "buddypress" ) 
    									. '</a>
    									</li>';
    								}
    
    

    But no work, can u help me correct it?
    when i click to logout, it went to error 404 with URL: domain.com/LogOut/a/li/ul/div/liliahref=

    #195091
     TheDream18
    Participant

    I fixed issue. Thanks

    #195115
     Radu
    Moderator

    OK
    Cheers
    R

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
Viewing 5 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic.

Log in with your credentials

Forgot your details?