Changing docroot using htaccess

I host all of my WordPress sites at Siteground, and I’d recommend them to anyone. They use Cpanel (which I’ve used for 15 years), they’re fast, and their service is exceptional.

I’m on their GoGeek plan (nice of them to name it that way), which means I have a lot of domains, all under Geekmum. And the one thing I had never got around to, was moving Geekmum to it’s own subfolder, instead of being splattered over the public_html folder, amongst the other sites.

Here’s a link on how to update your htaccess settings, to reference a different folder: https://www.siteground.com/kb/how_to_change_my_document_root_folder_using_an_htaccess_file/

This is also handy if you’re like my mate, who codes his production and testing sites in two separate folders, and needed a way to simply swap between the two locations when it was time to go live.

Similar Posts