Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #108816
    Flo
    Guest

    Hi,
    I made a staging environment (/staging) on my live site with total upkeep. It seemed to have worked fine but the links on the staging site don’t work properly: When hovering over the header menu some links show the correct staging path, but once you click on it I’m taken to the live website. Some links take me to the staging path and some show a 404 (mostly on higher path levels).
    Any ideas on that?

    Cheers, Flo

    #108875
    Brandon C
    Keymaster

    Hi Flo,

    I’m sorry to hear you’re experiencing difficulties with your staging environment created with Total Upkeep. This issue seems like it could be related to the URL settings in your destination installation.

    When you create a staging environment, WordPress should automatically update all the URLs to match the new staging path. However, in some cases, some URLs might not be updated correctly, causing the issues you’ve described.

    Here’s what you can do to resolve this:

    1. **Check and Update Permalinks:** Log in to your staging site’s WordPress admin dashboard. Go to Settings > Permalinks and simply click on the “Save Changes” button without making any changes. This forces WordPress to regenerate the .htaccess file, which might solve the issue.

    2. **Search and Replace URLs:** If the above step doesn’t solve the issue, you might need to manually update the URLs in your staging site’s database. You can use a plugin like “Better Search Replace” to do this. Be sure to backup your staging site before using search and replace tools.

    3. **Clear Cache:** Clear your browser cache and your website’s cache (if you’re using a caching plugin). Outdated cache files can sometimes cause issues with links and navigation.

    If you continue to face issues after trying these steps, please let us know and we’ll help you troubleshoot further.

    I hope this helps, please let us know if we can assist you further with this!

    #108894
    Flo
    Guest

    Thanks for your answer Brandon. Step 1 sort of repaired the header menu. Page links and the header logo link for example are still the same though.
    Before I go throuhg the manual replacement process – what could go wrong when I copy the staging website (including the inconsistent link structure) back to the live site after I made all necassary changes?
    As long as the /staging – links are switched again the others shouldn’t be Problem, am I right?
    And what about internal links I create new on the staging site – should I create them with the /staging pathstructure?
    Thanks, Flo

    #109006
    Brandon C
    Keymaster

    Hey Flo,

    I’m happy to hear you’re making progress! You’re right, as long as the /staging links are replaced correctly when pushing the site live, you should not have any issues. Here’s what you should note:

    1. When moving from staging to live, all instances of the “/staging URL” should be replaced with the live site URL. This includes internal links, images, scripts, etc. This is usually handled by a search and replace script or tool in the migration process.
    2. If you are creating new internal links on the staging site, you should create them with the /staging path structure. This is because when the site moves from staging to live, these links will be automatically updated to the correct URL structure.
    3. There could be issues if the replacements are not done correctly or fully. For example, if a /staging URL is hardcoded somewhere in the theme or plugins, it might not get replaced, leading to a broken link. So, it’s always good to double-check everything after the migration.
    4. As a best practice, it’s recommended to keep a backup of your live site before making any major changes like this. This way, you can always revert back if something goes wrong.

    I hope this helps clarify everything for you. Let us know if you have any other questions!

    #109162
    Flo
    Guest

    Hi Brandon,

    thank you so much for the very clearly structured answer!!

    Just to sum it up how to procede in my case:
    1. Backup live site – just in case
    2. Use total upkeep transfer – /staging links should be replaced automatically, links to live site will stay the same
    3. check with search/replace tool for any left over /staging links and in case replace them

    Thanks a bunch,
    Flo

    #109482
    Brandon C
    Keymaster

    You’re very welcome Flo!

    I believe you have it down!  Please don’t hesitate to let us know if you continue to have trouble we’re always here to help.

Viewing 6 posts - 1 through 6 (of 6 total)
  • The topic ‘Some links still point to my source site after Total Upkeep restoration’ is closed to new replies.