2

In our team we have a multi-language, multi-domain Typo3(6.2) installation with ~20 domains. The realurl config for the domains is working. My problem is, that if I want to link between domains I only get links with http://www.domainA.com/?id=PAGEID and not speaking urls.

The page tree looks like this:

root
  domainA
    page1  
  domainB
    page2
  ...

Now I want a link on page2 to page1.

This is the realurl_conf.php:

$languageMapping = array(
  'en' => '0',
  'de' => '1',
  'fr' => '2',
  ...
);
$liveDomains = array(
  "domainA.com" => "1",
  "domainA.de" => "1",
  "domainB.fr" => "2",
  ...
);

$liveDefault = array (
  'init' =>
  array (
    'enableCHashCache' => true,
    'appendMissingSlash' => 'ifNotFile,redirect[301]',
    'adminJumpToBackend' => true,
    'enableUrlDecodeCache' => true,
    'enableUrlEncodeCache' => true,
    'emptyUrlReturnValue' => '/',
  ),
  'pagePath' =>
  array (
    'type' => 'user',
    'userFunc' => 'EXT:realurl/class.tx_realurl_advanced.php:&tx_realurl_advanced->main',
    'spaceCharacter' => '-',
    'languageGetVar' => 'L',
    'rootpage_id' => '1',
  ),
  'fileName' =>
  array (
    'defaultToHTMLsuffixOnPrev' => 0,
    'acceptHTMLsuffix' => 1,
    'index' =>
    array (
      'print' =>
      array (
        'keyValues' =>
        array (
          'type' => 98,
        ),
      ),
    ),
  ),
  'preVars' =>
  array (
    0 =>
    array (
      'GETvar' => 'L',
      'valueMap' => $languageMapping,
      'noMatch' => 'bypass',
    ),
  ),
  "postVarSets" =>
  array (
    "_DEFAULT" =>
    array (
      "model" =>
      array (
        array (
          "GETvar" => "model"
        )
      ),
      "modelName" =>
      array (
        array (
          "GETvar" => "modelName"
        )
      ),
    ),
  ),
);
foreach ($liveDomains as $domain => $rootpage_id) {
  $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl']['www.'.$domain] = $liveDefault;
  $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl']['www.'.$domain]["pagePath"]["rootpage_id"] = $rootpage_id;
  $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['realurl'][$domain] = "www.".$domain;
}

In TS config.typolinkEnableLinksAcrossDomains = 1 is enabled.

Juburin
  • 133
  • 1
  • 8
  • What does your tsconfig for the page looks like? Did you set `config.tx_realurl_enable = 1` on each of your root pages? – Michael Apr 21 '15 at 07:39

1 Answers1

0

Bm you should add default pagePath like:

$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT']['pagePath']['rootpage_id'] = 1;
$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'] = $liveDefault;
Oleg V Karun
  • 726
  • 1
  • 6
  • 29