In /var/www/html I have a site dir. I've duplicated that site's dir and db into a new site dir and db by the name of "test" (without quote marks), and changed wp-config.php
accordingly.
I Navigated into this new site dir in console (cd /var/www/html/test
), and ran:
wp search-replace 'https://MY_ORIGIAL_DOMAIN' 'https://MY_IP/test'
The site itself goes up and its internal links become based on test
, but 2 problems occur:
- All css is jumbeled up.
- The original site's CSS is also jumbeled up (this is quite wired, I must say).
While I can reverse the result, I admit I don't understand what's going on (because I do everything in the new dir and not in the original dir).
Update
I was wrong, the db wasn't changed to test
in wp-config.php
... It seems my sed operation failed:
sed -i 's/${domain}/test'/g /var/www/html/test/wp-config.php