How to Change The Site URL of a Wordpress installation
I also make sure that the db name, user and password are the same on development and production server. Here is what I use to make the installation work i.e. Wordpress ignors the site url saved in the db.
Add these lines in config.php to make the installation work on dev and on production
define('WP_HOME','http://' . $_SERVER['HTTP_HOST']); define('WP_SITEURL','http://' . $_SERVER['HTTP_HOST']);
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)