We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 51452
    • 3 Posts
    Hi there,

    I tried to install MODX 2.4.2 last night. Naturally, I made a backup of my old modx folder on the server and of the database beforehand. However, the update did not work out, since my FTP client gave me error messages, saying that it was not able to replace certain files in my old 2.2.14 modx folder with the ones from the new 2.4.2 update.

    No problem, I rolled back to the backup 2.2.14 folder and loaded the website. It looked all fine, until I realised, that regardless of which link I click, it keeps showing me the website with ID=1 (although of course with friendly URL).

    Here are the things I tried so far:

    • turned off friendly_urls
    • emptied MODX cache
    • turned friendly_urls back on
    • tried to access the pages by using /index.php?id=number
    • when I try to view any other page than ID=1 from the manager, same thing: I only get to see the page with ID=1 on the front-end, although the URI clearly indicates that I am on the selected subpage
    • in the back-end/manager the subpages are still around, I can edit them and they are all published on a date in the past

    Now I am out of ideas. Can you help me?

    Thanks a lot!

    This question has been answered by multiple community members. See the first response.

    • discuss.answer
      • 3749
      • 24,544 Posts
      Forgive me if you already know this, but with friendly URLs off the .htaccess file should be renamed to ht.access (so it will be ignored). With friendly URLs on, it should be .htaccess.

      What you're seeing is what happens when MODX can't find the page. It forwards you to the page with the ID specified in the error_page System Setting (the default is 1). IIRC, it still shows the original URI.

      BTW, using FTP to transfer the MODX files individually often results in missing or corrupted files, even if there are no errors reported by the FTP client.

      Another possible issue is that you didn't mention backing up or restoring the DB. If you ran Setup with the new files, the DB would have been updated and might not match the old files you restored.

      Since you have a working Manager (and a backup), I think I would try downloading and installing UpgradeMODX, then using it to upgrade to 2.2.16, then to 2.3.6, then to 2.4.2.


        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting
        • 51452
        • 3 Posts
        Quote from: BobRay at Nov 30, 2015, 12:27 AM
        Forgive me if you already know this, but with friendly URLs off the .htaccess file should be renamed to ht.access (so it will be ignored). With friendly URLs on, it should be .htaccess.

        Thanks. I forgot all about that. Renamed the file now, and at least the site works now with ugly index.php?id=# URLs, so thanks for that.

        I never got to the setup stage of the new MODx version, since I knew that there were files missing. So there was no change to the database.

        Quote from: BobRay at Nov 30, 2015, 12:27 AM
        Since you have a working Manager (and a backup), I think I would try downloading and installing UpgradeMODX, then using it to upgrade to 2.2.16, then to 2.3.6, then to 2.4.2.

        When I am back home, I will try it.

        Once everything works as it should, I will report back and mark the thread as solved.
        • discuss.answer
          • 51452
          • 3 Posts
          Quote from: BobRay at Nov 30, 2015, 12:27 AM

          Since you have a working Manager (and a backup), I think I would try downloading and installing UpgradeMODX, then using it to upgrade to 2.2.16, then to 2.3.6, then to 2.4.2.

          I installed UpgradeMODX through the Package manager without any error messages and I can see the widget on the Dashboard. However, when I try to upgrade, it says, that it cannot find /upgrade.php (which is indeed nowhere to be found on the server), hence I cannot update through the UpgradeMODX package. I am logged in as Administrator.

          Whoever said "Never change a running system" was a wise person smiley Hope you can help. Thanks!

          EDIT:

          I unpacked the 2.4.2 update on the server instead of uploading it via FTP, did the upgrade as suggested, renamed the ht.access that came with the upgrade to .htaccess and switched the friendly_URLs back on - et voila: IT WORKS!

          Thanks for the patience. Problem solved [ed. note: yedrotulyudmek last edited this post 10 years, 9 months ago.]
            • 3749
            • 24,544 Posts
            I'm glad you got it sorted. smiley
              Did I help you? Buy me a beer
              Get my Book: MODX:The Official Guide
              MODX info for everyone: http://bobsguides.com/modx.html
              My MODX Extras
              Bob's Guides is now hosted at A2 MODX Hosting