• Hi

    I have transferred my site from one vps to another. I would like to keep my original domain and site intact and use the duplicate for some testing. I would therefore need to use the duplicate site with a temp url.

    After migrating the site, I edited the values in my database to reflect the temp url but the url still redirects to the main domain. I think I need to make some changes in my wo-config.php file as well as .htaccess but after playing about with it I haven’t been able to work out what to do.

    Any tips would be greatly appreciated.

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    Thread Starter s0206

    (@s0206)

    Thanks Ipstenu, that was the first document I read before posting. The parts I am struggling with is the changes to the wp-config.php and the htaccess.

    I can see in my wp-config file, there is a line: DOMAIN_CURRENT_SITE which stores the url for the domain but if I change this to the temp url it messes up. I can’t remember if I have to edit the $base value too.

    In my htaccess file do I replace all instances of the domain with the temp url?

    I wish I had kept some notes when I did this before 🙁

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    🏳️‍🌈 Advisor and Activist

    If the $base changes, yes, you need to change it.

    If your site is in example.com/wp/ then you should have:

    $base = '/wp/';
    define( 'DOMAIN_CURRENT_SITE', 'example.com' );
Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Temp url with network’ is closed to new replies.