We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 44580
    • 189 Posts
    Not sure when this started...

    Developing a new site. If I log into the Manager first and then go to the site, the site displays as normal.

    If I start a new browser session and go directly to the site I get the following:



    (Note the 404 in the header but a 503 message)

    I'm also getting some of these errors in the log: (ERROR @ /index.php) Attempted to redirect to an empty URL. But not always and not necessarily at the time I get the 404/ 503 message.

    I'm using Revo 2.2.10 on a Ubuntu 11.10 server. index.php and ht.access appear to be "standard" (certainly I've not changed them). Because I 99% of the time log into the Manager first, this could have been happening for weeks - as a result I have not the first clue what is happening or why.

    Help would be greatly appreciated.

    Robert.
      • 37514
      • 178 Posts
      Hi Robert,

      A few quick things:


      1. ht.access or .htaccess ? (you need to have moved it to the latter)
      2. Is the site published (check system settings for site_status )
      3. Is system setting site_start pointing to a published resource?

        • 44580
        • 189 Posts
        Hi Jim,

        Thanks for the suggestions and the quick response.

        1. It was the former, it is now the latter. I also edited Rewritebase. No change.
        2. Yes.
        3. Yes.

        I don't think it is FURL related (though I could be wrong) as I get the same error whether I use the url or the IP address.

        Any other ideas??

          • 3749
          • 24,544 Posts
          Have you created any permission rules that might be restricting access for anonymous users?

          Do you have any plugins enabled that relate to URLs?

          Is the site in a subdirectory?
            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
            • 44580
            • 189 Posts
            Hi Bob,

            I have created some groups and assigned resources to them. As best I can ascertain, I have taken no access away. Looking in the Resource Groups, the home page is available under the web context. I assume this means that anonymous has access? If not, how can I tell?

            The only plugin I have created is the one you've been helping me with - which extends the User form (nothing URL related).

            The site is one directory down from the root (ie /var/www/<directory>). If you are going to suggest changing .htaccess (rewritebase) to this directory - I did try that (no change in behaviour) but I just realized I did not restart Apache. Is this needed after making changes to .htaccess?

            Many thanks,

            Robert.

              • 37514
              • 178 Posts
              If you want to check permissions that is worth eliminating.

              You can check permissions for Anonymous in the Security » Access Controls; check that each context is listed for the Anonymous user group and is assigned an access policy of 'load only'.

              To be doubly safe, check the policy 'load only' looks correct, ie has the load only box ticked.

              This got me the other day, not sure how it got edited and broke but it did!
                • 3749
                • 24,544 Posts
                If you have a Resource Group connected to a User Group with a Resource Group Access ACL entry with a context of 'web' (or any front-end contect), that will hide the resources from anyone outside that group. The Resources will be "not found" by non group members in the front end.

                  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
                  • 44580
                  • 189 Posts
                  Thanks Bob, that was the problem (and thanks Jim for your suggestions also). Once I finally wrapped my head around this (kinda non-intuitive) concept, I figured I had two choices: add the anonymous user to the resource group, or remove the login page from the resource group.

                  So FYI for anyone else, to do the former, go to Security > Access Control, select anonymous, click on Resource Group Access > Add Resource Group and add the Resource group previously set up. After consideration, I decided the better option was to remove the login page from the resource group - which I did by going to the login page resource, clicking on Resource Groups and deselecting the ticked group(s).