We have multiple pagetrees for each region (e.g. Germany, Suisse). The pages themselves are translated to several languages (e.g. de, en) using the L-Parameter.
Now Realurl should match from 2 url segments to the approriate page tree and language. I know how this can be done with separate domains for each region using the _Domains feature. But in this case the domain stays always the same for all regions. Can this be achieved with Realurl and how?
http://example.com/de/de => should map to pagetree with rootpage_id 1 and language de (L=0)
http://example.com/de/en => should map to pagetree with rootpage_id 1 and language en (L=1)
http://example.com/ch/de => should map to pagetree with rootpage_id 2 and language de (L=0)
http://example.com/ch/en => should map to pagetree with rootpage_id 2 and language en (L=1)
real_url.conf
<?php
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl']['_DEFAULT'] = array(
'init' => array(
'enableCHashCache' => 1,
'appendMissingSlash' => 'ifNotFile,redirect',
'adminJumpToBackend' => 1,
'enableUrlDecodeCache' => 1,
'enableUrlEncodeCache' => 1,
'emptyUrlReturnValue' => '/'
),
'pagePath' => array(
'type' => 'user',
'userFunc' => 'EXT:realurl/class.tx_realurl_advanced.php:&tx_realurl_advanced->main',
'spaceCharacter' => '-',
'languageGetVar' => 'L',
'expireDays' => '3',
'rootpage_id' => 1,
'firstHitPathCache'=>1
),
'preVars' => array(
array(
'GETvar' => 'L',
'valueMap' => array(
'de' => '0',
'en' => '1',
),
'valueDefault' => 'de',
),
array(
'GETvar' => 'no_cache',
'valueMap' => array(
'no_cache' => 1,
),
'noMatch' => 'bypass',
),
),
);