I have been looking at whether it is possible to remove blog/
from the post & category URLs on the root node in a multisite setup.
I have found the multisite sites settings and removed the blog/
part of the URL and saved. Despite it changing all of the links correctly when I click them I just end up with a 404.
If I go to the node dashboard itself and resave I get the blog/
URL rewritten into the changed multisite permalinks. Sometimes creating something like this blog/news/postname
Has anyone managed to do this in the past? I am wondering if it is possible without hacking the core or getting a bit more hands on with some .htaccess
rules.
At blog site set
Settings -> Permalinks -> Common Setting -> Default
(Must select default only and don’t touch any thing, If you need to change category base, tag base set at Network Admin only)At Network
Admin -> Sites -> (root site) Permalink Sturcture -> /%category%/%post_id%
That it will remove /blog slug
Step 1: Go to
/wp-admin/network/site-info.php?id=1
Network Admin -> Sites -> Edit -> check Permalink Structure.
Edit as per your requirement.
Step 2: Go to normal site level
Settings -> Permalinks
Select or add appropriate permalink.
These are the steps.
Change the permalink setting in network admin to /%postname%/
Going to permalinks settings of the site will fix the 404
Result: Working WordPress Multisite without /blog/ slug.
Source with step-by-step screenshots.
Add a new page with
news
as slug. Go to Settings > Reading and choose your news-page as static page for blog posts.Then go to Settings > Permalink and customize your structure like
/%category%/%postname%/
and your blog post slugs should all be/news/post/
by now.At root site, Click on permalink and choose “plain”
At network level Site > click edit under the root site > Click on settings > Do a crtrl + F to find “Permalink Structure” > add %post_id% in the field.
For anyone looking for the answer as off Dec 2018 do the following.
Go to the network admin, select the root website and click edit.
Goto the settings tab. There is a massive list of options, look for the Permalink Structure field. remove /blog from the Permalink and hit save. I also went back to the root blogs admin area and clicked on the save button on the permalinks section to clear the cache.