How to transfer a WordPress blog to a different domain?

I recommend handling the 301 redirect in your web server rather than in WordPress. mod_rewrite or RedirectMatch will be much more efficient than spinning up WordPress to deliver a Location: header. <VirtualHost *:80> ServerName busted-cheap-url.com # mod_alias RedirectMatch permanent (.*) http://great-new-url.com$1 # OR mod_rewrite RewriteEngine on RewriteRule (.*) http://great-new-url.com$1 [R=301] </VirtualHost> There are several methods … Read more

Change site url when moving site to another url?

Those parameters and admin settings change the URLs in the database. The only other way to do that is run SQL queries on the DB in phpmyadmin to change them: UPDATE wp_options SET option_value = replace(option_value, ‘http://olddomain.com’, ‘http://newdomain.com’) WHERE option_name=”home” OR option_name=”siteurl”; UPDATE wp_posts SET guid = replace(guid, ‘http://olddomain.com’,’http://newdomain.com’); UPDATE wp_posts SET post_content = replace(post_content, … Read more

Git Deploying – Disabling plugin/theme installation/update on remote?

Set the constant DISALLOW_FILE_MODS to TRUE in your wp-config.php: const DISALLOW_FILE_MODS = TRUE; See the Codex for background information: Setting this constant also disables the Plugin and Theme editor (i.e. you don’t need to set DISALLOW_FILE_MODS and DISALLOW_FILE_EDIT, as on its own DISALLOW_FILE_MODS will have the same effect). It will also prevent installing or uninstalling … Read more

WordPress and Git Workflow

I’m one of the developers of WP Migrate DB Pro, and would like to answer @Ennui’s question: “Do you know if the db url replace script it runs takes into account serialized strings?” Yes, it does handle serialized data. In fact, that is the primary reason I developed the free version of the plugin back … Read more

Is Git/GitHub a good WordPress deployment solution?

I use git for this and find it works really well. A few suggestions: Add your uploads directory (wp-content/uploads) directory to your .gitignore file. Run a web server and database server on your development system so you can test changes locally before pushing them to production. Keep your database connection settings consistent beween dev and … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)