Skip to:
Content

BuddyPress.org

Changeset 8680


Ignore:
Timestamp:
07/23/2014 07:16:53 PM (6 years ago)
Author:
r-a-y
Message:

Replace wp_guess_url() with bp_get_requested_url().

wp_guess_url() doesn't work well with subdirectory installs and anyway,
bp_get_requested_url() is superior!

Fixes #5737.

Location:
trunk/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/bp-core-filters.php

    r8308 r8680  
    504504                $menu_item->_invalid = true;
    505505            } else {
    506                 $menu_item->url = wp_login_url( wp_guess_url() );
     506                $menu_item->url = wp_login_url( bp_get_requested_url() );
    507507            }
    508508
     
    513513                $menu_item->_invalid = true;
    514514            } else {
    515                 $menu_item->url = wp_logout_url( wp_guess_url() );
     515                $menu_item->url = wp_logout_url( bp_get_requested_url() );
    516516            }
    517517
  • trunk/src/bp-core/bp-core-widgets.php

    r8677 r8680  
    7070            <div class="bp-login-widget-user-links">
    7171                <div class="bp-login-widget-user-link"><?php echo bp_core_get_userlink( bp_loggedin_user_id() ); ?></div>
    72                 <div class="bp-login-widget-user-logout"><a class="logout" href="<?php echo wp_logout_url( wp_guess_url() ); ?>"><?php _e( 'Log Out', 'buddypress' ); ?></a></div>
     72                <div class="bp-login-widget-user-logout"><a class="logout" href="<?php echo wp_logout_url( bp_get_requested_url() ); ?>"><?php _e( 'Log Out', 'buddypress' ); ?></a></div>
    7373            </div>
    7474
  • trunk/src/bp-members/bp-members-adminbar.php

    r8677 r8680  
    5252            'id'    => 'bp-login',
    5353            'title' => __( 'Log in', 'buddypress' ),
    54             'href'  => wp_login_url( wp_guess_url() )
     54            'href'  => wp_login_url( bp_get_requested_url() )
    5555        ) );
    5656
Note: See TracChangeset for help on using the changeset viewer.