I have a 3.0.1 site with MULTISITE
enabled and would like one of the sites to live at /blog
, but when I try to create a new site with that path, I get this error:
The following words are reserved for use by WordPress functions and cannot be used as blog names: page, comments, blog, files, feed
How can I get a site at /blog
?
You can’t.
That’s part of the main site’s permalink structure. There’s no way to get around it. You can find more information here:
http://core.trac.wordpress.org/ticket/13527
Yes, you can I get a site at
/blog
running inMULTISITE
, but that needs adding some code. That’s because WordPress has a child-proof lock build in that you need to unlock first. This can be done by adding a hook function into thesubdirectory_reserved_names
filter that passes an array with names that are blocked as parameter. Remove the entries you’d like to use and return the filtered array.Take care because this child-proof lock has been build so that the words ‘page’, ‘comments’, ‘blog’, ‘files’, ‘feed’ could not be used by default.
/blog
for example is reserved for the main site.For more information please see ticket #13304, the related change that allows to override the reserved names was 14928
Actually, the root site can have blog as a part of the permalink structure. In fact, any nice-urls for root site’s posts force the prefix blog.
So, if you don’t mind using root account, you can have it. But you have to be careful, as the main blog can show up in subsites’ panels, etc (AFAIK).
I have
/blog
subsite for years now and actually i don’t think that it’s any of issue. In functions.php, add this code:There is a way, I have done it before but it was on WPMU 2.X – not sure if they made it tougher to remove in 3, I can’t imagine why they would have.
this is a plugin to remove the /blog part – http://buddydev.com/http//buddydev.com/public-download/cc-remove-blog-slug-v-1.1.zip – as for writing the actual /blog/ permalink to the site, wp will filter that, the easies way is create the “blog” subsite with a wierd enough url that it is quickly found in phpMyAdmin (set the path to “yoursite.com/wtfisgoingonhere”) then log intop phpmyadmin search for it, and replace all instances with /blog/ – be very careful not to remove or add an extra slash anywhere. Good luck!