Tag Archives: Wordpress

Moving WordPress

OK, this is going to be a very short post, more of a mental note than a tutorial, about moving a WordPress install. The task was to move from sub.example.com to example.com where the files for example.com were to be stored in a folder rather than the root of the www directory (the www folder hosted multiple sites). Basically I followed this tutorial, skipping steps 12 – 15. I would add to this tutorial that you need to download and edit the following lines in your wp-config.php file;

define( 'WP_CONTENT_DIR', '/home/hosting/public_html/sub.example.com/wordpress-content' );
define( 'WP_CONTENT_URL', 'http://sub.example.com/wordpress-content' );

to reflect the new URLs

define( 'WP_CONTENT_DIR', '/home/hosting/public_html/example.com/wordpress-content' );
define( 'WP_CONTENT_URL', 'http://example.com/wordpress-content' );

This was the change that made everything appear as it should. From here I could re-apply my custom theme and have all my plugins show up without errors.

Phoenix

So, earlier on this week my wordpress was hacked. I went for a clean WP and database install, which seemed the safest option and have taken steps to harden this new installation.
The positives are that I am now a lot more familiar with the cPanel backup options, however I have lost my old posts. I will attempt to reconstruct these over the next few days.