Hmmm... Don't think I quite get all the required setup yet.
When going to my site nearlynewnearyou.co.uk (after making it so that it will use the local version) I get "Error establishing a database connection"
In my httpd.conf I have:
<VirtualHost 127.0.0.1>
DocumentRoot "C:/wamp/www/nearlynewnearyou.co.uk"
ServerName nearlynewnearyou.co.uk
ServerAlias *.nearlynewnearyou.co.uk
ErrorLog "C:/wamp/www/nearlynewnearyou.co.uk/errors/errors.log"
</VirtualHost>
In my wp-config I have (some details changed as I guessed it would cause a security issue if it were the real data):
define('DB_NAME', 'mydbname');
define('DB_USER', 'myusername');
define('DB_PASSWORD', 'mypassword');
define('DB_HOST', 'localhost');
define('WP_HOME', 'http://nearlynewnearyou.co.uk');
define('WP_SITEURL', 'http://nearlynewnearyou.co.uk');
and my hosts looks like this:
127.0.0.1 localhost
127.0.0.1 nearlynewnearyou.co.uk
127.0.0.1 warwick.nearlynewnearyou.co.uk
127.0.0.1 halloween.nearlynewnearyou.co.uk
myphpadmin shows that I have a database called 'mydname' (matches what is in wp-config) and under privileges of that db a user called 'myusername' with a password of 'mypassword' (both match what is in wp-config) and set to have all privileges.
I have exported the live site db 'mydbname' and then imported that data back into the local 'mydbname'
I also ftp'd all the live sites public_html into C:\wamp\www\nearlynewnearyou.co.uk\
Any idea what I could have done wrong to get that error?