How to enable /wp-admin on subdomains
I’ve created 2 subdomains for my domain.com: dev.domain.com and dev2.domain.com.
I created them by copying databases and apache configs. I made the necessary changes in apache configs and enabled them, but did nothing with databases for now.
So dev. dev2. domains are working - I can open them and when I change something on domain.com these changes do not impact dev. and dev2.
But there’s one problem. When I am trying to connect to dev.domain.com/wp-admin and dev2.domain.com/wp-admin they both redirect me to domain.com/wp-admin.
Can you please guide me to where I must make changes to enable dev. and dev2 /wp-admin to work independently from each other and from domain.com.
If I am not mistaken I must change something in my databases.
Please ask if you need more information.
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.×