[TYPO3] Two languages with different domains. How to configure?
Dmitry Dulepov [typo3]
dmitry at typo3.org
Thu Aug 9 09:41:11 CEST 2007
Hi!
Morten Kjems wrote:
> I am having trouble to get my language configuration configured correctly.
>
> My site runs on two languages that are attached to a domain each.
>
> Like this:
>
> domain.dk: danish (default language)
> domain.com: english
>
> It is a one page three solution with TV where all pages are localized. I
> am using RealURL.
>
> What I would like to achieve is this:
>
> If a user enters the site by domain.com he should stay on that domain
> and the urls generated should be like this
> "domain.com/home/article.html" and not something like
> "domain.dk/en/home/article.html"
>
> Also when a flag is clicked in the language navigation link should
> reflect the domain as described above. When I click a flag now - lets
> say from a domain.dk page the link generated will be
> domain.dk/en/home/article.html. However if I type
> domain.com/home/article.html directly in the browser it works just fine.
>
> This leads to another problem: All my articles are available from
> several URLs. This is confusing and will penalized by the search
> engines. Each article will be accessible with three different URLs:
> - domain.dk/en/home/article.html
> - domain.com/en/home/article.html
> - domain.com/home/article.html
>
> All suggestions on how solve these errors are most welcome.
- domain.dk/en should redirect to domain.en by .htaccess with 301 code
- domain.en/dk should redirect to domain.dk by .htaccess with 301 code
- realurl should have separate configuration for both domains with
default language configured as preVar with default value that
corresponds to domain ('en' for 'domain.en')
- you have to write a userFunc for language selector to perform logic as
you need: (1) strip language suffix and (2) put correct domain to
typolink's generated page path
--
Dmitry Dulepov
TYPO3 freelancer / TYPO3 core team member
Web: http://typo3bloke.net/
Skype: callto:liels_bugs
More information about the TYPO3-english
mailing list