Make WordPress Core

Ticket #32525: 32525.2.patch

File 32525.2.patch, 4.1 KB (added by Fab1en, 9 years ago)

Add a link to the dashboard in Network > Edit site page for all tabs

  • src/wp-admin/network/site-info.php

    ---
     src/wp-admin/network/site-info.php     | 4 +++-
     src/wp-admin/network/site-settings.php | 4 +++-
     src/wp-admin/network/site-themes.php   | 4 +++-
     src/wp-admin/network/site-users.php    | 4 +++-
     4 files changed, 12 insertions(+), 4 deletions(-)
    
    diff --git a/src/wp-admin/network/site-info.php b/src/wp-admin/network/site-info.php
    index 87ca256..2983756 100644
    a b $site_url_no_http = preg_replace( '#^http(s)?://#', '', get_blogaddress_by_id( $ 
    9191$title_site_url_linked = sprintf( __( 'Edit Site: %s' ), '<a href="' . get_blogaddress_by_id( $id ) . '">' . $site_url_no_http . '</a>' );
    9292$title = sprintf( __( 'Edit Site: %s' ), $site_url_no_http );
    9393
     94$dashboard = '<a href="' . get_admin_url( $id ) . '">' . __( '(go to dashboard)' ) . '</a>';
     95
    9496$parent_file = 'sites.php';
    9597$submenu_file = 'sites.php';
    9698
    require( ABSPATH . 'wp-admin/admin-header.php' ); 
    99101?>
    100102
    101103<div class="wrap">
    102 <h2 id="edit-site"><?php echo $title_site_url_linked ?></h2>
     104<h2 id="edit-site"><?php echo $title_site_url_linked ?> <small><?php echo $dashboard ?></small></h2>
    103105<h3 class="nav-tab-wrapper">
    104106<?php
    105107$tabs = array(
  • src/wp-admin/network/site-settings.php

    diff --git a/src/wp-admin/network/site-settings.php b/src/wp-admin/network/site-settings.php
    index ecf8a12..ba140a8 100644
    a b $site_url_no_http = preg_replace( '#^http(s)?://#', '', get_blogaddress_by_id( $ 
    7979$title_site_url_linked = sprintf( __( 'Edit Site: %s' ), '<a href="' . get_blogaddress_by_id( $id ) . '">' . $site_url_no_http . '</a>' );
    8080$title = sprintf( __( 'Edit Site: %s' ), $site_url_no_http );
    8181
     82$dashboard = '<a href="' . get_admin_url( $id ) . '">' . __( '(go to dashboard)' ) . '</a>';
     83
    8284$parent_file = 'sites.php';
    8385$submenu_file = 'sites.php';
    8486
    require( ABSPATH . 'wp-admin/admin-header.php' ); 
    8789?>
    8890
    8991<div class="wrap">
    90 <h2 id="edit-site"><?php echo $title_site_url_linked ?></h2>
     92<h2 id="edit-site"><?php echo $title_site_url_linked ?> <small><?php echo $dashboard ?></small></h2>
    9193<h3 class="nav-tab-wrapper">
    9294<?php
    9395$tabs = array(
  • src/wp-admin/network/site-themes.php

    diff --git a/src/wp-admin/network/site-themes.php b/src/wp-admin/network/site-themes.php
    index 384f58c..06a9618 100644
    a b $site_url_no_http = preg_replace( '#^http(s)?://#', '', get_blogaddress_by_id( $ 
    133133$title_site_url_linked = sprintf( __( 'Edit Site: %s' ), '<a href="' . get_blogaddress_by_id( $id ) . '">' . $site_url_no_http . '</a>' );
    134134$title = sprintf( __( 'Edit Site: %s' ), $site_url_no_http );
    135135
     136$dashboard = '<a href="' . get_admin_url( $id ) . '">' . __( '(go to dashboard)' ) . '</a>';
     137
    136138$parent_file = 'sites.php';
    137139$submenu_file = 'sites.php';
    138140
    139141require( ABSPATH . 'wp-admin/admin-header.php' ); ?>
    140142
    141143<div class="wrap">
    142 <h2 id="edit-site"><?php echo $title_site_url_linked ?></h2>
     144<h2 id="edit-site"><?php echo $title_site_url_linked ?> <small><?php echo $dashboard ?></small></h2>
    143145<h3 class="nav-tab-wrapper">
    144146<?php
    145147$tabs = array(
  • src/wp-admin/network/site-users.php

    diff --git a/src/wp-admin/network/site-users.php b/src/wp-admin/network/site-users.php
    index 57a189b..5a8b6f3 100644
    a b $site_url_no_http = preg_replace( '#^http(s)?://#', '', get_blogaddress_by_id( $ 
    161161$title_site_url_linked = sprintf( __( 'Edit Site: %s' ), '<a href="' . get_blogaddress_by_id( $id ) . '">' . $site_url_no_http . '</a>' );
    162162$title = sprintf( __( 'Edit Site: %s' ), $site_url_no_http );
    163163
     164$dashboard = '<a href="' . get_admin_url( $id ) . '">' . __( '(go to dashboard)' ) . '</a>';
     165
    164166$parent_file = 'sites.php';
    165167$submenu_file = 'sites.php';
    166168
    var current_site_id = <?php echo $id; ?>; 
    182184
    183185
    184186<div class="wrap">
    185 <h2 id="edit-site"><?php echo $title_site_url_linked ?></h2>
     187<h2 id="edit-site"><?php echo $title_site_url_linked ?> <small><?php echo $dashboard ?></small></h2>
    186188<h3 class="nav-tab-wrapper">
    187189<?php
    188190$tabs = array(