We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 44661
    • 31 Posts
    Hi,
    Using Revo 2.4.3pl on a personnal site i am currently editing/updating.

    Once editing a resource inside the manager and using the VIEW menu to see/check the edited resource, i get www.example.comResourceName.html causing a browser error due to the missing /, instead of www.example.com/ResourceName.html
    the other manager menu links such as Save, Close, ... work fine.

    I have checked my htaccess, the system settings (identical to older sites i have running fine on prior versions of Revo), the friendly URLs which work fine too, etc

    Any clue on what i should check/edit to fix this "bugging" (small) bug ?

    Many thanks for yr help !

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

    [ed. note: justinet last edited this post 9 years, 11 months ago.]
      • 3749
      • 24,544 Posts
      That's an odd one. It should use the same site_url used by links on the site, which you say are working. The relevant paths and URLs in core/config/config.inc.php should end with a trailing slash, but if they didn't, I'd expect to see other problems at the site. The same with .htaccess.

      I'm not sure if it exists in that version, but if it does, try Manage -> Clear Cache -> Refresh URIs on the top menu.

      Is the container_suffix System Setting a single slash?



        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
        • 44661
        • 31 Posts
        Hi Bob,
        Thanks a lot for looking into this.
        This small bug is annoying, but no big deal as the site and all the menus are running OK

        This is just at the manager level.
        Yes i have cleared the cache and refresh urls a few times and confirming the content in system settings of the container_suffix is :" / " (i.e. a single slash)
        Actually just the first slash is missing as : www.example.comResourceName.html (VIEW link in manager); with a container resource i have the second slash appearing, but not the first one e.g. www.example.comContainerResource/ResourceName.html

        I thought there could be something wrong with the site url, but i havent seen any manual setting is system settings and again the whole site, besides this manager issue, is running OK ! weird or a stupid mistake from my side (i haven't been involved much with site devlpts lately ... and catching up)
        Thanks again,


        Just found out (i am using Babel for this multilingual site) it works OK for other languages i.e. translations e.g. www.example.com/2 letters language suffix/ResourceName.html
        so perhaps an issue with the first (web) context setting ?? [ed. note: justinet last edited this post 9 years, 11 months ago.]
          • 3749
          • 24,544 Posts
          That sounds like a good bet. Make sure all the Context Setting URLs end with a slash, especially the site_url setting.

          The site_url is created on-the-fly based on the URL the user comes in on, so there's no editable System Setting for it. You can see it, though with a tag in a resource:

          [[!++site_url]]


          It's also possible that a URL in the core/config/config.inc.php file doesn't end with a slash but Babel is correcting it, just not all the time.
            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
            • 44661
            • 31 Posts
            Thanks Bob

            Yes the enclosure of the tag [[!++site_url]] in a resource yields "http://www.example.com" i.e. without a slash at the end, which likely leads to that issue.

            I have looked into the core/config/config.inc.php file and added a slash after the site url in a couple of lines (lines 62 and 65 i.e. when/in case the MODX_HTTP_HOST is not defined), cleared cache/refreshed urls but that didn't solve the pb.


            In manage contexts and settings i just see the various language keys and web for the primary site language and default front end context, but do not see any context setting urls and especially any site_url setting ?
            • discuss.answer
              • 3749
              • 24,544 Posts
              I don't have any real experience with multi-context sites, but it's my understanding that the various contexts should all have the following Context Settings created:

              site_url
              base_url
              site_start
                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
                • 44661
                • 31 Posts
                Hi Bob,
                You are right, adding a slash in the multilingual context settings for the site_url solved the problem.

                Access to the context settings is via a right click on each context (i had forgotten that !)

                Many thanks again for your kind help on this despite my ignorance.
                All the best
                  • 3749
                  • 24,544 Posts
                  I'm glad I could help. 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