Results 1 to 2 of 2

Thread: Why does baseURL contain both httpXForwardedHost + httpHost

  1. #1
    New user
    Join Date
    10-31-11.
    Posts
    28

    Default Why does baseURL contain both httpXForwardedHost + httpHost

    I see a lot of posts and closed bugs because the server incorrectly sets httpXForwardedHost. However, I don't think this is the case as I really am using forwarding.

    I have test.theaterwerk-bodensee.de forwarded to tw.alien878.de. Unfortunately, when I go to http://test.theaterwerk-bodensee.de the baseURL ends up as:

    Code:
    <base href="http://test.theaterwerk-bodensee.de/tw.alien878.de/" />
    when it should be:
    Code:
    <base href="http://test.theaterwerk-bodensee.de/" />
    Why is it adding the httpHost? I can fix this in function url of Environment.php, but that doesn't seem to be the right answer.

    Allen

  2. #2
    New user
    Join Date
    02-18-12.
    Posts
    1

    Default Re: Why does baseURL contain both httpXForwardedHost + httpH

    I assisted a client install contao on our services at WebFaction today and had a similar issue.

    We use a front-end nginx proxy server to route URLs and so this was happening. I resolved it by adding this,

    ./settings/config/localconfig.php
    Code:
    $_SERVER ['HTTP_X_FORWARDED_FOR'] ='';
    $_SERVER ['HTTP_X_FORWARDED_HOST'] ='';
    It would be nice to have some increased documentation on baseURL, how it is built, and ways to override it.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •