diff --git a/wp-admin/options-permalink.php b/wp-admin/options-permalink.php index 79374936c8..0b490071af 100644 --- a/wp-admin/options-permalink.php +++ b/wp-admin/options-permalink.php @@ -82,7 +82,7 @@ if ( isset($_POST['permalink_structure']) || isset($_POST['category_base']) ) { $permalink_structure = $_POST['permalink_structure']; if (! empty($permalink_structure) ) $permalink_structure = preg_replace('#/+#', '/', '/' . $_POST['permalink_structure']); - if ( is_multisite() && !is_subdomain_install() && $permalink_structure != '' && $current_site->domain.$current_site->path == $current_blog->domain.$current_blog->path ) { + if ( is_multisite() && !is_subdomain_install() && $permalink_structure != '' && is_main_site() ) { $permalink_structure = '/blog' . $permalink_structure; } $wp_rewrite->set_permalink_structure($permalink_structure); @@ -92,7 +92,7 @@ if ( isset($_POST['permalink_structure']) || isset($_POST['category_base']) ) { $category_base = $_POST['category_base']; if (! empty($category_base) ) $category_base = preg_replace('#/+#', '/', '/' . $_POST['category_base']); - if ( is_multisite() && !is_subdomain_install() && $category_base != '' && $current_site->domain.$current_site->path == $current_blog->domain.$current_blog->path ) { + if ( is_multisite() && !is_subdomain_install() && $category_base != '' && is_main_site() ) { $category_base = '/blog' . $category_base; } $wp_rewrite->set_category_base($category_base); @@ -102,7 +102,7 @@ if ( isset($_POST['permalink_structure']) || isset($_POST['category_base']) ) { $tag_base = $_POST['tag_base']; if (! empty($tag_base) ) $tag_base = preg_replace('#/+#', '/', '/' . $_POST['tag_base']); - if ( is_multisite() && !is_subdomain_install() && $tag_base != '' && $current_site->domain.$current_site->path == $current_blog->domain.$current_blog->path ) { + if ( is_multisite() && !is_subdomain_install() && $tag_base != '' && is_main_site() ) { $tag_base = '/blog' . $tag_base; } $wp_rewrite->set_tag_base($tag_base); @@ -203,7 +203,7 @@ $structures = array( - domain.$current_site->path == $current_blog->domain.$current_blog->path ) { echo "/blog"; $permalink_structure = str_replace( "/blog", "", $permalink_structure ); }?> + @@ -219,11 +219,11 @@ $structures = array( - + - +
domain.$current_site->path == $current_blog->domain.$current_blog->path ) { echo "/blog"; $category_base = str_replace( "/blog", "", $category_base ); }?>
domain.$current_site->path == $current_blog->domain.$current_blog->path ) { echo "/blog"; $tag_base = str_replace( "/blog", "", $tag_base ); }?>