~canonical-sysadmins/wordpress/4.2.4

« back to all changes in this revision

Viewing changes to wp-admin/network/site-settings.php

  • Committer: Paul Gear
  • Date: 2015-04-24 01:35:20 UTC
  • mfrom: (1.1.4 upstream)
  • Revision ID: paul.gear@canonical.com-20150424013520-w4p9ksth76zh6opw
Merge new upstream release 4.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
 
30
30
get_current_screen()->set_help_sidebar(
31
31
        '<p><strong>' . __('For more information:') . '</strong></p>' .
32
 
        '<p>' . __('<a href="http://codex.wordpress.org/Network_Admin_Sites_Screen" target="_blank">Documentation on Site Management</a>') . '</p>' .
 
32
        '<p>' . __('<a href="https://codex.wordpress.org/Network_Admin_Sites_Screen" target="_blank">Documentation on Site Management</a>') . '</p>' .
33
33
        '<p>' . __('<a href="https://wordpress.org/support/forum/multisite/" target="_blank">Support Forums</a>') . '</p>'
34
34
);
35
35
 
40
40
 
41
41
$details = get_blog_details( $id );
42
42
if ( !can_edit_network( $details->site_id ) )
43
 
        wp_die( __( 'You do not have permission to access this page.' ) );
 
43
        wp_die( __( 'You do not have permission to access this page.' ), 403 );
44
44
 
45
45
$is_main_site = is_main_site( $id );
46
46
 
76
76
}
77
77
 
78
78
$site_url_no_http = preg_replace( '#^http(s)?://#', '', get_blogaddress_by_id( $id ) );
79
 
$title_site_url_linked = sprintf( __('Edit Site: <a href="%1$s">%2$s</a>'), get_blogaddress_by_id( $id ), $site_url_no_http );
80
 
$title = sprintf( __('Edit Site: %s'), $site_url_no_http );
 
79
$title_site_url_linked = sprintf( __( 'Edit Site: %s' ), '<a href="' . get_blogaddress_by_id( $id ) . '">' . $site_url_no_http . '</a>' );
 
80
$title = sprintf( __( 'Edit Site: %s' ), $site_url_no_http );
81
81
 
82
82
$parent_file = 'sites.php';
83
83
$submenu_file = 'sites.php';
105
105
<?php
106
106
if ( ! empty( $messages ) ) {
107
107
        foreach ( $messages as $msg )
108
 
                echo '<div id="message" class="updated"><p>' . $msg . '</p></div>';
 
108
                echo '<div id="message" class="updated notice is-dismissible"><p>' . $msg . '</p></div>';
109
109
} ?>
110
110
<form method="post" action="site-settings.php?action=update-site">
111
111
        <?php wp_nonce_field( 'edit-site' ); ?>
138
138
                        if ( strpos( $option->option_value, "\n" ) !== false ) {
139
139
                        ?>
140
140
                                <tr class="form-field">
141
 
                                        <th scope="row"><?php echo ucwords( str_replace( "_", " ", $option->option_name ) ) ?></th>
 
141
                                        <th scope="row"><label for="<?php echo esc_attr( $option->option_name ) ?>"><?php echo ucwords( str_replace( "_", " ", $option->option_name ) ) ?></label></th>
142
142
                                        <td><textarea class="<?php echo $class; ?>" rows="5" cols="40" name="option[<?php echo esc_attr( $option->option_name ) ?>]" id="<?php echo esc_attr( $option->option_name ) ?>"<?php disabled( $disabled ) ?>><?php echo esc_textarea( $option->option_value ) ?></textarea></td>
143
143
                                </tr>
144
144
                        <?php
145
145
                        } else {
146
146
                        ?>
147
147
                                <tr class="form-field">
148
 
                                        <th scope="row"><?php echo esc_html( ucwords( str_replace( "_", " ", $option->option_name ) ) ); ?></th>
 
148
                                        <th scope="row"><label for="<?php echo esc_attr( $option->option_name ) ?>"><?php echo esc_html( ucwords( str_replace( "_", " ", $option->option_name ) ) ); ?></label></th>
149
149
                                        <?php if ( $is_main_site && in_array( $option->option_name, array( 'siteurl', 'home' ) ) ) { ?>
150
150
                                        <td><code><?php echo esc_html( $option->option_value ) ?></code></td>
151
151
                                        <?php } else { ?>