Last active
August 12, 2017 07:39
-
-
Save lorenzulrich/19407e8cfbf6a1af21ab to your computer and use it in GitHub Desktop.
TYPO3: One domain per language with RealURL
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[globalVar = GP:L=1] | |
config { | |
sys_language_uid = 1 | |
language = en | |
locale_all = en_CH.utf8 | |
htmlTag_langKey = en | |
baseURL = http://default.domain.tld/ | |
} | |
[global] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl'] = array( | |
'default.domain.tld' => array( | |
'init' => array( | |
'enableCHashCache' => true, | |
'appendMissingSlash' => 'ifNotFile,redirect', | |
'adminJumpToBackend' => true, | |
'enableUrlDecodeCache' => true, | |
'enableUrlEncodeCache' => true, | |
'emptyUrlReturnValue' => '/' | |
), | |
'pagePath' => array( | |
'type' => 'user', | |
//'disablePathCache' => true, | |
'userFunc' => 'EXT:realurl/class.tx_realurl_advanced.php:&tx_realurl_advanced->main', | |
'spaceCharacter' => '-', | |
'languageGetVar' => 'L', | |
'rootpage_id' => '2' | |
), | |
'fileName' => array( | |
'defaultToHTMLsuffixOnPrev' => 0, | |
'acceptHTMLsuffix' => 0 | |
), | |
'preVars' => array( | |
array( | |
'GETvar' => 'L', | |
'valueMap' => array( | |
'de' => 0, | |
'en' => 1 | |
), | |
'valueDefault' => 'de', | |
'noMatch' => 'bypass' | |
) | |
), | |
'postVarSets' => array( | |
'_DEFAULT' => array( | |
) | |
) | |
), | |
'_DOMAINS' => array( | |
'encode' => array( | |
array( | |
'GETvar' => 'L', | |
'value' => '0', | |
'useConfiguration' => 'default.domain.tld', | |
'urlPrepend' => 'http://default.domain.tld', | |
'ifDifferentToCurrent' => 'true' | |
), | |
array( | |
'GETvar' => 'L', | |
'value' => '1', | |
'useConfiguration' => 'secondary.domain.tld', | |
'urlPrepend' => 'http://secondary.domain.tld', | |
'ifDifferentToCurrent' => 'true' | |
) | |
), | |
'decode' => array( | |
'default.domain.tld' => array( | |
'GETvars' => array( | |
'L' => '' | |
), | |
'useConfiguration' => 'default.domain.tld' | |
), | |
'secondary.domain.tld' => array( | |
'GETvars' => array( | |
'L' => '1' | |
), | |
'useConfiguration' => 'secondary.domain.tld' | |
) | |
) | |
) | |
); | |
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl']['secondary.domain.tld'] = $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl']['default.domain.tld']; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment