We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 28689
    • 2 Posts
    Basic info:
    OS: Ubuntu desktop 8.10
    Webserver: Apache2 2.2.12
    PHP: 5.2.10
    MySQL: 5.1.37

    Note: My understanding of MODx, Ubuntu etc. is limited. So I may not know exactly what I’m talking about...

    Problem:
    As you can see by the link below, URLs to images and links are using ’localhost’ as the base_url, so naturally images and links don’t work properly when browsed from anywhere besides the server.
    I’ve been searching for info about where MODx fetches the base_url from, to no avail.

    I basically need to make my base_url (or site_url) setting to make everything point at *snip due to solved*, or in some other make it so that my MODx site can be browsed properly (relative links?).

    As pretty much everything has been freshly installed, I have not changed any settings in Apache, PHP, MySQL or MODx. The MODx installation is meant to run on the server (not meant to migrate to a different host).

    Link to site:
    *snip due to solved*

    Any and all help would be greatly appreciated!
      • 16278
      • 928 Posts
      Try <base href="[(site_url)]" /> in the HEAD part of your site template(s) instead of <base href="http://localhost/modx/"></base> that is currently showing there.
      smiley KP
        • 28689
        • 2 Posts
        So I had a look at my template (default one) through the manager interface after previously been editing it through the .tpl file.

        I had a look in it, confirmed that it did have <base href="[(site_url)]"></base> in it. Didn’t change anything and saved it. And now it works!

        I hate it when I don’t change anything and stuff starts working >.<

        Thanks tho wink