das Problem mit den falschen URLs zu beheben
http://www.site2.com Passwort vergessen Links
http://www.site1.com/wp-login.php?action = lostpassword
und nicht
http://www.site2.com/wp-login.php?action = lostpassword
die Lösung ist,:
ändern Sie auf den meisten Linien network_site_url -> Seiten-URL
wp-includes / general-template.php
1 2 3 4 5 6 7 8 9 |
function wp_lostpassword_url( $redirect = '' ) { $args = array( 'action' => 'lostpassword' ); if ( !empty($redirect) ) { $args['redirect_to'] = $redirect; } $lostpassword_url = add_query_arg( $args, network_site_url('wp-login.php', 'login') ); return apply_filters( 'lostpassword_url', $lostpassword_url, $redirect ); } |
sollte sein
1 2 3 4 5 6 7 8 9 |
function wp_lostpassword_url( $redirect = '' ) { $args = array( 'action' => 'lostpassword' ); if ( !empty($redirect) ) { $args['redirect_to'] = $redirect; } $lostpassword_url = add_query_arg( $args, site_url('wp-login.php', 'login') ); return apply_filters( 'lostpassword_url', $lostpassword_url, $redirect ); } |
Auch Wordpress generiert die falsche E-Mail in wp-login.php
1 2 3 4 5 6 |
$message = __('Someone requested that the password be reset for the following account:') . "rnrn"; $message .= network_home_url( '/' ) . "rnrn"; $message .= sprintf(__('Username: %s'), $user_login) . "rnrn"; $message .= __('If this was a mistake, just ignore this email and nothing will happen.') . "rnrn"; $message .= __('To reset your password, visit the following address:') . "rnrn"; $message .= '<' . network_site_url("wp-login.php?action=rp&key=$key&login=" . rawurlencode($user_login), 'login') . ">rn"; |
sollte sein
1 2 3 4 5 6 |
$message = __('Someone requested that the password be reset for the following account:') . "rnrn"; $message .= home_url( '/' ) . "rnrn"; $message .= sprintf(__('Username: %s'), $user_login) . "rnrn"; $message .= __('If this was a mistake, just ignore this email and nothing will happen.') . "rnrn"; $message .= __('To reset your password, visit the following address:') . "rnrn"; $message .= '<' . site_url("wp-login.php?action=rp&key=$key&login=" . rawurlencode($user_ |
1 |
<form name="lostpasswordform" id="lostpasswordform" action="<?php echo esc_url( network_site_url( 'wp-login.php?action=lostpassword', 'login_post' ) ); ?>" method="post"> |
sollte sein
1 |
<form name="lostpasswordform" id="lostpasswordform" action="<?php echo esc_url( site_url( 'wp-login.php?action=lostpassword', 'login_post' ) ); ?>" method="post"> |
1 |
$login_header_url = network_home_url(); |
sollte sein
1 |
$login_header_url = home_url(); |
1 |
wp_die( __('The e-mail could not be sent.') . "<br />n" . __('Possible reason: your host may have disabled the mail() function.') ); |
sollte sein
1 |
wp_die( __('The e-mail could not be sent.') . "<br />n" . __('Possible reason: your host may have disabled the mail() function, or enable the Plugin WP-Mail-SMTP and configure it.') ); |
1 |
$blogname = ['current_site']->site_name; |
sollte sein
1 |
$blogname = home_url( '/' ); |