WordPress.org

Make WordPress Core

Ticket #39311: fix-wp-activate.39311.5..diff

File fix-wp-activate.39311.5..diff, 3.7 KB (added by pkarjala, 5 months ago)

Fixes formatting changes requested by whyisjake; tested on 5.5-beta2-48482

  • wp-activate.php

    diff --git a/wp-activate.php b/wp-activate.php
    index 3258c07d32..3009db38d1 100644
    a b add_action( 'wp_head', 'wpmu_activate_stylesheet' ); 
    117117add_action( 'wp_head', 'wp_sensitive_page_meta' );
    118118
    119119get_header( 'wp-activate' );
     120
     121$blog_details = get_blog_details();
    120122?>
    121123
    122124<div id="signup-content" class="widecolumn">
    get_header( 'wp-activate' ); 
    124126        <?php if ( ! $key ) { ?>
    125127
    126128                <h2><?php _e( 'Activation Key Required' ); ?></h2>
    127                 <form name="activateform" id="activateform" method="post" action="<?php echo network_site_url( 'wp-activate.php' ); ?>">
     129                <form name="activateform" id="activateform" method="post" action="<?php echo network_site_url( $blog_details->path . 'wp-activate.php' ); ?>">
    128130                        <p>
    129131                                <label for="key"><?php _e( 'Activation Key:' ); ?></label>
    130132                                <br /><input type="text" name="key" id="key" value="" size="50" />
    get_header( 'wp-activate' ); 
    146148                                printf(
    147149                                        /* translators: 1: Login URL, 2: Username, 3: User email address, 4: Lost password URL. */
    148150                                        __( 'Your account has been activated. You may now <a href="%1$s">log in</a> to the site using your chosen username of &#8220;%2$s&#8221;. Please check your email inbox at %3$s for your password and login instructions. If you do not receive an email, please check your junk or spam folder. If you still do not receive an email within an hour, you can <a href="%4$s">reset your password</a>.' ),
    149                                         network_site_url( 'wp-login.php', 'login' ),
     151                                        network_site_url( $blog_details->path . 'wp-login.php', 'login' ),
    150152                                        $signup->user_login,
    151153                                        $signup->user_email,
    152154                                        wp_lostpassword_url()
    get_header( 'wp-activate' ); 
    155157                                printf(
    156158                                        /* translators: 1: Site URL, 2: Username, 3: User email address, 4: Lost password URL. */
    157159                                        __( 'Your site at %1$s is active. You may now log in to your site using your chosen username of &#8220;%2$s&#8221;. Please check your email inbox at %3$s for your password and login instructions. If you do not receive an email, please check your junk or spam folder. If you still do not receive an email within an hour, you can <a href="%4$s">reset your password</a>.' ),
    158                                         sprintf( '<a href="http://%1$s">%1$s</a>', $signup->domain ),
     160                                        sprintf( '<a href="http://%1$s%2$s">%1$s%2$s</a>', $signup->domain, $blog_details->path ),
    159161                                        $signup->user_login,
    160162                                        $signup->user_email,
    161163                                        wp_lostpassword_url()
    get_header( 'wp-activate' ); 
    196198                                <p class="view">
    197199                                <?php
    198200                                        /* translators: 1: Login URL, 2: Network home URL. */
    199                                         printf( __( 'Your account is now activated. <a href="%1$s">Log in</a> or go back to the <a href="%2$s">homepage</a>.' ), network_site_url( 'wp-login.php', 'login' ), network_home_url() );
     201                                        printf(
     202                                                __( 'Your account is now activated. <a href="%1$s">Log in</a> or go back to the <a href="%2$s">homepage</a>.' ),
     203                                                network_site_url( $blog_details->path . 'wp-login.php', 'login' ),
     204                                                network_home_url( $blog_details->path ) );
    200205                                ?>
    201206                                </p>
    202207                                <?php
  • wp-includes/general-template.php

    diff --git a/wp-includes/general-template.php b/wp-includes/general-template.php
    index 8d6ab511fb..cf511ac5c9 100644
    a b function wp_lostpassword_url( $redirect = '' ) { 
    609609        if ( ! empty( $redirect ) ) {
    610610                $args['redirect_to'] = urlencode( $redirect );
    611611        }
     612        $args['action'] = "lostpassword";
    612613
    613         $lostpassword_url = add_query_arg( $args, network_site_url( 'wp-login.php?action=lostpassword', 'login' ) );
     614        $blog_details = get_blog_details();
     615
     616        $lostpassword_url = add_query_arg( $args, network_site_url( $blog_details->path . 'wp-login.php', 'login' ) );
    614617
    615618        /**
    616619         * Filters the Lost Password URL.