WordPress.org

Make WordPress Core

Ticket #9241: 9241.diff

File 9241.diff, 788 bytes (added by Denis-de-Bernardy, 9 years ago)
  • wp-includes/general-template.php

     
    137137 * @since 1.5.0
    138138 * @uses apply_filters() Calls 'loginout' hook on HTML link content.
    139139 */
    140 function wp_loginout() {
     140function wp_loginout($redirect = '') {
    141141        if ( ! is_user_logged_in() )
    142                 $link = '<a href="' . wp_login_url() . '">' . __('Log in') . '</a>';
     142                $link = '<a href="' . wp_login_url($redirect) . '">' . __('Log in') . '</a>';
    143143        else
    144                 $link = '<a href="' . wp_logout_url() . '">' . __('Log out') . '</a>';
     144                $link = '<a href="' . wp_logout_url($redirect) . '">' . __('Log out') . '</a>';
    145145
    146146        echo apply_filters('loginout', $link);
    147147}