diff --git a/src/wp-login.php b/src/wp-login.php index 6c5769c4ef..507a122af5 100644 --- a/src/wp-login.php +++ b/src/wp-login.php @@ -430,6 +430,15 @@ do_action( "login_form_{$action}" ); $http_post = ('POST' == $_SERVER['REQUEST_METHOD']); $interim_login = isset($_REQUEST['interim-login']); +/** + * Filters the separator used between login form navigation links. + * + * @since 4.9.0 + * + * @param string $login_link_separator The separator used between login form navigation links. + */ +$login_link_separator = apply_filters( 'login_link_separator', ' | ' ); + switch ($action) { case 'postpass' : @@ -555,8 +564,10 @@ case 'retrievepassword' : if ( get_option( 'users_can_register' ) ) : $registration_url = sprintf( '%s', esc_url( wp_registration_url() ), __( 'Register' ) ); + echo esc_html( $login_link_separator ); + /** This filter is documented in wp-includes/general-template.php */ - echo ' | ' . apply_filters( 'register', $registration_url ); + echo apply_filters( 'register', $registration_url ); endif; ?>
@@ -668,8 +679,10 @@ case 'rp' : if ( get_option( 'users_can_register' ) ) : $registration_url = sprintf( '%s', esc_url( wp_registration_url() ), __( 'Register' ) ); + echo esc_html( $login_link_separator ); + /** This filter is documented in wp-includes/general-template.php */ - echo ' | ' . apply_filters( 'register', $registration_url ); + echo apply_filters( 'register', $registration_url ); endif; ?> @@ -744,7 +757,8 @@ case 'register' : @@ -936,7 +950,9 @@ default: $registration_url = sprintf( '%s', esc_url( wp_registration_url() ), __( 'Register' ) ); /** This filter is documented in wp-includes/general-template.php */ - echo apply_filters( 'register', $registration_url ) . ' | '; + echo apply_filters( 'register', $registration_url ); + + echo esc_html( $login_link_separator ); endif; ?>