My site is preparing to go live. As updations are developed on my site, I would like to test the updations in real server without affecting the real data. I need 2 databases(the same database with 2 names) to connect my site at the same time. One for testing myself and other for the real users.
I tried duplicating the config/main to config/main_test and the main index.php to index_test.php. And implemented 2 database connections in config/main.php and config/main_test.php. And connected those files to the index.php and index_test.php and tried to run the site with http://mysite.com/index.php and http://mysite.com/index_test.php. But both urls are working based on the database connection provided in config/main.php.
How can I get use the 2 databases? I dont think keeping 2 copies of the entire site is a good idea. All suggestions are welcome