The was I normaly misrate sites is:
- setup a new WordPress site on the target host (so the database etc is set up)
- note down database settings (wp-config.php)
- export the database from existing site
- drop all tables from database target host created
- import the tables from existing install
- delete all public_html the files from the target install
- FTP all the files from existing install
- change database details in the target WordPress install back to the ones that were setup when I created the new target install (which have now been overittern by FTP I just did)
The last one has got me stumped. The new install uses wp-config.php which has the DB configuration:
define( 'DB_NAME', 'followthe_wp886' );
define( 'DB_USER', 'followthe_wp886' );
define( 'DB_PASSWORD', 'r4]1Q4p7)A-S)x[1' );
define( 'DB_HOST', 'localhost' );
define( 'DB_CHARSET', 'utf8' );
define( 'DB_COLLATE', '' );
But the old one used setup-config.php and used:
$dbname = trim( wp_unslash( $_POST['dbname'] ) );
$uname = trim( wp_unslash( $_POST['uname'] ) );
$pwd = trim( wp_unslash( $_POST['pwd'] ) );
$dbhost = trim( wp_unslash( $_POST['dbhost'] ) );
$prefix = trim( wp_unslash( $_POST['prefix'] ) );
could just set these to the relevent values but I feer an update bay break this ;(.
Or maybe I just put wp-config.php in install and delete setup-config.php?
Any help on unraveling this would be good. Maybe I should
Regards,
Ben
You are correct – remove “setup-config.php” – that is non-standard. `wp-config.php` is what you should be using.