user image

Shilpa
Published in : 2022-03-01

How to run wordpress with different themes in main domain and subdomain?

Wordpress

I got one task to add wordpress installation on my main domain (let's say, rubixc*****.com). my Client decided one theme for this website.

They want to use another theme for subdomain (alpha.rubixc*****.com).

Do I need to install a separate installation for subdomain? - If yes, it will be hard to manage all the subdomains (7+ subdomains) and update all the plugins, Updating SSL, testing, and too many deployments, Overall the maintenance costs will be increased!

Is there any solution to overcome this requirement?

Comments

Rakshit Date : 2022-03-05

Best answers

34

Best answers

34

All you need is to set up Multisite Network to your respective domain's root directory.

TL;DR;

This is solution for “One wordpress installation for all subdomains using Multisite network”

Install wordpress to your root directory and add below comment at the bottom of  “wp-config.php” file,

/* Enable Multisite using below line */define( 'WP_ALLOW_MULTISITE', true );

Open your website and login with your WP User credentials,

After that, You can now head over to Tools > Network Setup page to configure your multisite network.

You can visit wordpress dashboard for all subdomains you want to create. You can individually manage themes plugins pages and posts.

Ref: Visit here for the best guide

Hope, it will work for you.

Leave a comment

Join us

Join our community and get the chance to solve your code issues & share your opinion with us

Sign up Now

Related posts

A custom WordPress Login page and URL
Publish date: 2022-02-10 | Comments: 2

Tag: Wordpress

Way to disable Block URLs for WordPress Posts
Publish date: 2022-02-26 | Comments: 2

Tag: Wordpress

Cpanel to Webmin migration 503 error
Publish date: 2021-08-12 | Comments: 4

Tag: Wordpress

What is the best reference to the most used WordPress functions?
Publish date: 2022-02-09 | Comments: 2

Tag: Wordpress

A Site Kit WordPress plugin bug.
Publish date: 2022-02-10 | Comments: 2

Tag: Wordpress

[solved] undefined $post->ID in WP_Query()
Publish date: 2022-01-30 | Comments: 2

Tag: Wordpress

How to display tags on each posts for customized wordpress theme?
Publish date: 2022-02-26 | Comments: 1

Tag: Wordpress