I am glad that I have set up multiple environments for a current project that I’m working on. The live site, a testing site, and two developing sites – all with their unique databases just in case something’s going very Murphy – are a fair deal to develop and test new features and bugfixes on any web project. But there’s one major drawback: Keeping data “in sync”. Version control like git or SVN do a great job with all that PHPs,
After explaining, how to use Different database connections in WordPress development environments, I’m going to show, how to set up Magento development environments with different database connections. Magento works a little different here, since it has its database connection in an XML file rather than a configuration .php-file.
Since I am using version control with GIT, I have set up different environments for my current WordPress/Magento-married project. For this project, I did not want to continue “cowboy coding”, so I set up a remote staging / testing / development site and multiple local development sites. Each site has its own purpose and needs its own MySQL database. So I had to handle different database connections in my WordPress installations. Well, I could work with only one DB,