We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 34084 ☆ A M B ☆
    • 756 Posts
    By default the scheme property is set to use relative URL's, so make sure you don't have that parameter set to use full url see the documentation. Thus one other thing to check is if you have the
    <base href="[[++site_url]]" />
    set in your template, if so try removing that and test.

    cheers
      Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
      Visit CharlesMx.com for latest news and status updates.
      • 22303 MODX Staff
      • 10,725 Posts
      Don't remove, just make sure it is not cached:

      <base href="[[!++site_url]]">
        • 34084 ☆ A M B ☆
        • 756 Posts
        if he leaves this in then it will always use the installed site domain URL in the full link resource, correct? Unless this pulls the actual URI used to access the site and uses it vs. the URI used during the install/setup??

        Example:
        Ran setup on (http://first-domain-name.com) then the site_url would always return that domain name vs. if I actually access the site from http://live-domain-name.com

        Just curious as this has been an issue I've run into in the past with multiple domains pointed to a single site instance. Agreed that this is not ideal to use mutiple domains names for the same site however sometimes the client overrules and/or custom TV's are used to swap the branding.

        Cheers
          Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
          Visit CharlesMx.com for latest news and status updates.
          • 10076
          • 1,024 Posts
          Cheers, that works fine, not sure about the htaccess because the mod rewrite I tried previously also is on the source site so rewrites that url?, but it works fine. Thanks opengeek.

          And @charles, i think it s a normal situation where more domains point to the same webserver IP, eg google.com googel.com gogggle.com etc.

          Thanks.
            • 22303 MODX Staff
            • 10,725 Posts
            Quote from: charless at Dec 21, 2011, 11:39 AM
            if he leaves this in then it will always use the installed site domain URL in the full link resource, correct? Unless this pulls the actual URI used to access the site and uses it vs. the URI used during the install/setup??
            It will use the HTTP_HOST the client sent as a header unless the web server is configured to send a specific HTTP_HOST. MODX dynamically constructs the site_url on each request in the config file from $_SERVER['HTTP_HOST'], though you can override this via System or Context settings. The only thing that will not dynamically change is the base_url which is appended to the url_scheme and http_host settings.
              • 34084 ☆ A M B ☆
              • 756 Posts
              great, thanks for the clarification
                Evo Revo // Ubuntu, CentOS, Win // Apache 2x, Lighttp (Lighty)
                Visit CharlesMx.com for latest news and status updates.