diff --git wp-admin/network/site-info.php wp-admin/network/site-info.php index bcc71f9..8071b25 100644 --- wp-admin/network/site-info.php +++ wp-admin/network/site-info.php @@ -49,8 +49,15 @@ if ( isset($_REQUEST['action']) && 'update-site' == $_REQUEST['action'] ) { switch_to_blog( $id ); + $url_parts = parse_url( 'http://' . $_POST['blog']['url'] ); + unset( $_POST['blog']['url'] ); + + $_POST['blog']['domain'] = $url_parts['host']; + $_POST['blog']['path'] = $url_parts['path']; + if ( isset( $_POST['update_home_url'] ) && $_POST['update_home_url'] == 'update' ) { $blog_address = get_blogaddress_by_domain( $_POST['blog']['domain'], $_POST['blog']['path'] ); + if ( get_option( 'siteurl' ) != $blog_address ) update_option( 'siteurl', $blog_address ); @@ -74,6 +81,7 @@ if ( isset($_REQUEST['action']) && 'update-site' == $_REQUEST['action'] ) { update_blog_details( $id, $blog_data ); restore_current_blog(); + wp_redirect( add_query_arg( array( 'update' => 'updated', 'id' => $id ), 'site-info.php') ); exit; } @@ -122,28 +130,24 @@ if ( ! empty( $messages ) ) {
+ | + | - | domain ) ?> |
-
- - - |
---|---|---|---|---|
- - | path ) ?> |
-
+
-
- /> siteurl and home as well.' ); ?> |
+
+
+
+ ||