WordPress.org

Make WordPress Core

Ticket #13087: 13087.patch

File 13087.patch, 6.3 KB (added by ocean90, 8 years ago)
  • wp-signup.php

     
    99require_once( ABSPATH . WPINC . '/registration.php' );
    1010
    1111if ( is_array( get_site_option( 'illegal_names' )) && isset( $_GET[ 'new' ] ) && in_array( $_GET[ 'new' ], get_site_option( 'illegal_names' ) ) == true ) {
    12         wp_redirect( "http://{$current_site->domain}{$current_site->path}" );
     12        wp_redirect( network_home_url() );
    1313        die();
    1414}
    1515
     
    2828}
    2929
    3030if ( !is_main_site() ) {
    31         wp_redirect( "http://" . $current_site->domain . $current_site->path . "wp-signup.php" );
     31        wp_redirect( network_home_url( 'wp-signup.php' ) );
    3232        die();
    3333}
    3434
     
    7575        if ( !is_subdomain_install() )
    7676                echo '<span class="prefix_address">' . $current_site->domain . $current_site->path . '</span><input name="blogname" type="text" id="blogname" value="'. esc_attr($blogname) .'" maxlength="50" /><br />';
    7777        else
    78                 echo '<input name="blogname" type="text" id="blogname" value="'.esc_attr($blogname).'" maxlength="50" /><span class="suffix_address">.' . $current_site->domain . $current_site->path . '</span><br />';
     78                echo '<input name="blogname" type="text" id="blogname" value="'.esc_attr($blogname).'" maxlength="50" /><span class="suffix_address">.' . $current_site->domain . '</span><br />';
    7979
    8080        if ( !is_user_logged_in() ) {
    8181                print '(<strong>' . __( 'Your address will be ' );
     
    9898        <div id="privacy">
    9999        <p class="privacy-intro">
    100100            <label for="blog_public_on"><?php _e('Privacy:') ?></label>
    101             <?php _e('I would like my site to appear in search engines like Google and Technorati, and in public listings around this network.'); ?>
     101            <?php _e('Allow my blog to appear in search engines like Google, Technorati, and in public listings around this network.'); ?>
    102102            <div style="clear:both;"></div>
    103103            <label class="checkbox" for="blog_public_on">
    104104                <input type="radio" id="blog_public_on" name="blog_public" value="1" <?php if ( !isset( $_POST['blog_public'] ) || $_POST['blog_public'] == '1' ) { ?>checked="checked"<?php } ?> />
     
    137137        <?php if ( $errmsg = $errors->get_error_message('user_email') ) { ?>
    138138                <p class="error"><?php echo $errmsg ?></p>
    139139        <?php } ?>
    140         <input name="user_email" type="text" id="user_email" value="<?php  echo esc_attr($user_email) ?>" maxlength="200" /><br /><?php _e('(We&#8217;ll send your password to this address, so <strong>triple-check it</strong>.)') ?>
     140        <input name="user_email" type="text" id="user_email" value="<?php  echo esc_attr($user_email) ?>" maxlength="200" /><br /><?php _e('(Double-check your email address before continuing.)') ?>
    141141        <?php
    142142        if ( $errmsg = $errors->get_error_message('generic') ) {
    143143                echo '<p class="error">' . $errmsg . '</p>';
     
    177177                        <?php _e( 'Sites you are already a member of:' ) ?>
    178178                        <ul>
    179179                                <?php foreach ( $blogs as $blog ) {
    180                                         echo "<li><a href='http://" . $blog->domain . $blog->path . "'>" . $blog->domain . $blog->path . "</a></li>";
     180                                        echo "<li><a href='" . esc_url( get_home_url( $blog->userblog_id ) ). "'>" . get_home_url( $blog->userblog_id ) . "</a></li>";
    181181                                } ?>
    182182                        </ul>
    183183                </p>
     
    360360        <h2><?php printf( __( 'Congratulations! Your new site, %s, is almost ready.' ), "<a href='http://{$domain}{$path}'>{$blog_title}</a>" ) ?></h2>
    361361
    362362        <p><?php _e( 'But, before you can start using your site, <strong>you must activate it</strong>.' ) ?></p>
    363         <p><?php printf( __( 'Check your inbox at <strong>%s</strong> and click the link given. It should arrive within 30 minutes.' ),  $user_email) ?></p>
     363        <p><?php printf( __( 'Check your inbox at <strong>%s</strong> and click the link given.' ),  $user_email) ?></p>
    364364        <p><?php _e( 'If you do not activate your site within two days, you will have to sign up again.' ); ?></p>
    365365        <h2><?php _e( 'Still waiting for your email?' ); ?></h2>
    366366        <p>
    367367                <?php _e( 'If you haven&#8217;t received your email yet, there are a number of things you can do:' ) ?>
    368368                <ul id="noemail-tips">
    369                         <li><p><strong><?php _e( 'Wait a little longer.  Sometimes delivery of email can be delayed by processes outside of our control.' ) ?></strong></p></li>
    370                         <li><p><?php _e( 'Check the junk or spam folder of your email client.  Sometime emails wind up there by mistake.' ) ?></p></li>
    371                         <li><?php printf( __( 'Have you entered your email correctly?  We think it&#8217;s %s but if you have entered it incorrectly, you will not receive it.' ), $user_email ) ?></li>
     369                        <li><p><strong><?php _e( 'Wait a little longer. Sometimes delivery of email can be delayed by processes outside of our control.' ) ?></strong></p></li>
     370                        <li><p><?php _e( 'Check the junk or spam folder of your email client. Sometime emails wind up there by mistake.' ) ?></p></li>
     371                        <li><?php printf( __( 'Have you entered your email correctly?  You have entered %s, if it&#8217;s incorrectly, you will not receive your email.' ), $user_email ) ?></li>
    372372                </ul>
    373373        </p>
    374374        <?php
     
    383383$active_signup = apply_filters( 'wpmu_active_signup', $active_signup ); // return "all", "none", "blog" or "user"
    384384
    385385if ( is_super_admin() )
    386         echo '<div class="mu_alert">' . sprintf( __( 'Greetings Site Administrator! You are currently allowing &#8220;%s&#8221; registrations. To change or disable registration go to your <a href="wp-admin/ms-options.php">Options page</a>.' ), $active_signup ) . '</div>';
     386        echo '<div class="mu_alert">' . sprintf( __( 'Greetings Site Administrator! You are currently allowing &#8220;%s&#8221; registrations. To change or disable registration go to your <a href="%s">Options page</a>.' ), $active_signup, esc_url( network_admin_url( 'ms-options.php' ) ) ) . '</div>';
    387387
    388388$newblogname = isset($_GET['new']) ? strtolower(preg_replace('/^-|-$|[^-a-zA-Z0-9]/', '', $_GET['new'])) : null;
    389389
     
    424424                        elseif ( is_user_logged_in() == false && ( $active_signup == 'all' || $active_signup == 'user' ) )
    425425                                signup_user( $newblogname, $user_email );
    426426                        elseif ( is_user_logged_in() == false && ( $active_signup == 'blog' ) )
    427                                 _e( 'We are sorry. We are not accepting new registrations at this time.' );
     427                                _e( 'Sorry, new registrations are not allowed at this time.' );
    428428                        else
    429429                                _e( 'You are logged in already. No need to register again!' );
    430430