We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4542
    • 7 Posts
    I have used modX for this site since Evo, and ever since I recreated it with Revo I have had intermittent problems with logging in to the manager interface.

    I get the same "loops back to the manager login" as others, and yes, I have checked the posts here and nothing seems to fix it.

    Except, that is, after a reinstall. After install, I can log in but no other users can, and once I've logged out it's reinstall time again.

    I'm on hostgator, and am using 2.2.4.pl as of now.

    If I can't get this fixed, I'm off to another system...argh!

    This question has been answered by Camwyn. See the first response.

    [ed. note: Camwyn last edited this post 14 years, 2 months ago.]
      • 33968
      • 863 Posts
      What do you mean, you enter your manager login details and instead of seeing the Dashboard you end up back on the login form?

      Something might be up with your cookies. Deleting them should fix the issue at the time but you'll want to work out what's causing it. If you can get into the manager, Flush All Sessions should let the others in too.

      Are you hosting more than one site (such as a dev version) on the same domain? I've experienced this while trying to persist manager sessions across subdomains, are you doing anything like that?
        • 4542
        • 7 Posts
        Yes, enter manager login info and instead of going to the dashboard you get redirected to the login screen again and again.

        I have cleared cookies, emptied the browser cache, checked and manually set the session path, tried using the Db session options in the dashboard, tried requesting a new password (always tells me I have the wrong code - it hasn't worked correctly ever)

        I'm not hosting more than one site, but it is on a shared hosting platform.

        Later today I'm going to try backing up the database and starting from scratch, then importing just the pages table...
          • 10208 ☆ A M B ☆
          • 1,780 Posts
          Have you checked your manager permissions for your user? Is your user the default admin or a new user? Check to see that your user has super user permissions set, and if not, set to super user.

          I've seen this before on a Hostgator install, from QuickInstall. It doesn't set the permissions properly. I haven't used their installer for a while, the last time I did it left out the assets folder, and added one with their install files.
            Frogabog- MODX Websites in Portland Oregon
            "Do yourself a favor and get a copy of "MODX - The Official Guide" by Bob Ray. Read it.
            Having server issues? These guys have MODX Hosting perfected - SkyToaster
            • 4542
            • 7 Posts
            Both a default admin and a new one. I haven't double-checked the permissions, but if that's the problem there are bigger issues with ModX - since I was logged in immediately after install (and could do all admin functions then) and it was only after I logged out that I had a problem.

            It's not a packaged install from HG - I did the install manually with the most recent zipped version from here.
              • 4542
              • 7 Posts
              OK, so I have tracked down the issue but I have yet to solve it.

              If I go to mysite.com/manager and try to log in I get the loop.

              If I go to mysite.com/~mysite/manager and try to log in it works.

              My guess is there is a setting somewhere (in the database?) from when I set up the site before we pointed the domain to the new server...now to figure out where it is and how to fix it...
              • discuss.answer
                • 4542
                • 7 Posts
                OK, so for anyone else that has this issue:

                If you have set up the site using the temporary url, ModX saves the paths in core/config/config.inc.php

                Look there and remove the /~mysite portion of four links
                In mine they were at lines
                35: $modx_connectors_url
                41: $modx_manager_url
                47: $modx_base_url (note here I changed it from "/~mysite/" to "/")
                and 79: $modx_assets_url

                Hope this helps someone else!
                  • 10208 ☆ A M B ☆
                  • 1,780 Posts
                  Quote from: Camwyn at Jul 12, 2012, 11:47 AM
                  OK, so for anyone else that has this issue:

                  If you have set up the site using the temporary url, ModX saves the paths in core/config/config.inc.php

                  Look there and remove the /~mysite portion of four links
                  In mine they were at lines
                  35: $modx_connectors_url
                  41: $modx_manager_url
                  47: $modx_base_url (note here I changed it from "/~mysite/" to "/")
                  and 79: $modx_assets_url

                  Hope this helps someone else!

                  I'm a little confused about the further issues with Camwyn's install because the above solution worked just fine.

                  I ran into this exact issue while moving a site from one host to Hostgator this weekend (and remembered this post, TG). This happens when MODX is installed before the nameservers are changed, thus you're working in a temporary user account (and using access paths consisting of http://IP Address/~username/). Running setup after the nameservers have propagated doesn't change the config.inc.php paths, and it has to be done manually.

                  Once I changed these paths, the manager was available via http://sitename.com/manager as expected.

                  The only thing I did different was to re-run setup before I made the path changes.

                  For others using Hostgator (excellent MODX hosting btw, really I have no complaints), to reduce the occurrence of such an issue, don't install MODX until the namservers have propagated. The fix is easy, but if you can afford the 24 hours just wait and simplify the installation.

                  I also don't exactly recommend using their QuickInstall module for MODX. Last time I used it, it added weird installation folders and left out the assets folder completely (I notified them of this). A manual install always works, plus that way you can name your database and default admin user as desired.
                    Frogabog- MODX Websites in Portland Oregon
                    "Do yourself a favor and get a copy of "MODX - The Official Guide" by Bob Ray. Read it.
                    Having server issues? These guys have MODX Hosting perfected - SkyToaster
                    • 4542
                    • 7 Posts
                    So, for future issues others may have:

                    A month later, the looping started again. I reread every thread on the forum about login loops I could find and nothing seemed to work.
                    On a hunch, I checked the modx_sessions table in phpmyqdmin - bingo!

                    The table had crashed and needed to be repaired - that fixed the looping.

                    HTH