[TYPO3-english] Problem with baseURL and multiple domains

Joerg Schoppet joerg at schoppet.de
Mon Jul 20 22:09:02 CEST 2009


Hi,

I have the following structure

ROOT
   - example-page
     - index
       - page1
       - page2
       - page3

index is the startpage and page1 to page3 are the navigation of the site.

Within the index-page I have created a domain-record "www.example.de" and in TS-config I've made the following settings
config.baseURL = http://www.example.de/
config.tx_realurl_enable = 1 (yes, I have a running realurl-ext)

When I open the startpage (index) in FE, everything looks good in the sourcecode:
- base is correctly set
- all links starting correct (e.g. href="page1/index.html")

But as soon as I call one of the sub-pages (page1-page3), all links are replaces by "complete" links (e.g. href="http://www.example.de/page2/index.html").

???

This would normally not such a problem, but as soon as I create an additional domain-record within the startpage (index) (e.g. "www.example.com") the problems start.

In TS-config I've made the following additional settings:
[globalString = ENV:HTTP_HOST=www.example.com]
   config.baseURL = http://www.example.com/
[global]

Now, clearing all caches and browsing to the startpage with "www.example.com", sourcecode - again - looks good:
- base is correctly set
- all links start correct (e.g. href="page1/index.html")

But as soon as I call one of the sub-pages, the sourcecode is ...
- base is correctly set to http://www.example.com/
- *BUT* all links look like that (e.g. href="http://www.example.de/page2/index.html")
                                                                 ^^

So, not only, that the links are written "complete", they are also prepended with the domain of the first domain-record.


Please, can anybody give me a help/hint/tip?

Joerg


More information about the TYPO3-english mailing list