I have a wordpress Multisite instance that for some reason defaults to domain.com (/blog with no www in front. Any request with a www in front gets forced to the home page (domain.com/blog) and not to it’s intended page of say domain.com/blog/page.
What I am trying to do is force all incoming traffic to strip off www if it exists and just go to /blog/what-ever-page-youre-trying-to-go-to. I need it to go to the page that is requested, currently if you have anything on the end of the /blog URL (/blog/ANY-PAGE-HERE) it defaults to /blog.
Anyone have any idea how I would go about fixing this? In .htaccess seems to be the easiest way but I can’t seem to find a viable solution after working on it for a couple of hours.
PS: it’s multisite so I cannot just go into setting and change the URL and HOME to www.domain/blog
This is what I use on my sites:
Add this above all your wordpress stuff in the htaccess of your document root: