[opencms-dev] where is "create sibling"
] Code Create [
ocms at code-create.de
Fri Feb 27 18:41:31 CET 2015
Why "once again" ? :)
In your ".com" vHost you rewrite internally to your /en/ folder and in
your ".de" vHost you rewrite internally to your /de/ folder.
That apart, I don't understand your /opencms/ to
http://www.mysite.whatever/ permanent redirects. Seems like an endless
loop if that happens inside a www.mysite.whatever vHost?!
Your vHosts (for www.mysite.com and www.mysite.de) get a request for
their relevant domain e. g. www.mysite.com, and in that vHost you
rewrite the url to you the relevant folder e. g. /en/.
Then you do your whatever internal rewrites to the opencms servlet, e.
g. via mod_jk, the best method to do this.
I do not see, where there is any permanent redirect necessary in this
scenario; always involving one more indirection via the user's browser.
In your opencns-system.xml you may also do something like:
<site server="http://www.mysite.de" uri="/sites/mysite/" ... >
<alias server="http://www.mysite.com" />
</site>
Am 27.02.2015 um 16:35 schrieb Christoph Kukulies:
> Am 27.02.2015 um 16:09 schrieb ] Code Create [:
>> Hi Christoph,
>>
>> why do you do the redirect at all?
>> You're already differentiating by TLD.
>> Why not just rewrite internally to your /de/ and /en/ folders via Apache?
>>
>> Kind regards, Bernd
>>
>>
> Good question. Maybe historically reasoned. My site is in ROOT and I'm
> doing the rewrite rules in two VirtualHost sections, one for mysite.com,
> the other for mysite.de. The former
> does
>
> RedirectPermanent /opencms/ http://www.mysite.com/
>
> the latter
>
> RedirectPermanent /opencms/ http://www.mysite.de/
>
> In opencms-system.xml I have
>
> <site server="http://www.mysite.de" uri="/sites/mysite/"/>
> <site server="http://www.mysite.com" uri="/sites/mysite/"/>
>
> So I will have to decide once again, where the request is redirected to.
>
> Or do you have a better suggestion?
>
>
>
More information about the opencms-dev
mailing list