Zum Inhalt springen

realurl: mehrere domains, sprachen und auch verschiedene rootpage_id

Erstellt am 20. April 2013 · Noch keine Antworten

Tags: RealURL, URLs & Routing, Frage

miela ·

Hallo,

in der Installation gibt es mehrere domains, die unterschiedlich mit den Sprachversionen umgehen:

Domain1 gibt es in den Versionen .de, .com, .gr und soll entsprechend der Sprache die Domain (tld) wechseln.
Die Rootpage ID ist 1.

Domain2 gibt es nur in der Version .com und soll bei Sprachwechsel ein "/en" oder "/gr" hinzugefügt bekommen.
Die Rootpage ID ist 143.

Alle Sprachen sind als onepagetree angelegt.

Beide Varianten alleine bekomme ich zu laufen, aber wie lassen sie sich kombinieren?

Die realurl_conf für Domain1 schaut so aus:

<?php 
$RootPID = array(
'www.domain1.de' => '1',
'www.domain1.com' => '1',
'www.domain1.gr' => '1',
'www.domain2.com' => '143',
);

$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DOMAINS'] = array( 
         'encode' => array( 
                 array( 
                         'GETvar' => 'L', 
                         'value' => '0', 
                         'useConfiguration' => '_DEFAULT', 
                         'urlPrepend' => 'http://www.domain1.de'
                 ), 
                 array( 
                         'GETvar' => 'L', 
                         'value' => '1', 
                         'useConfiguration' => '_DEFAULT', 
                         'urlPrepend' => 'http://www.domain1.com'
                 ), 
                 array( 
                         'GETvar' => 'L', 
                         'value' => '2', 
                         'useConfiguration' => '_DEFAULT', 
                         'urlPrepend' => 'http://www.domain1.gr'
                 ), 
         ), 
         'decode' => array( 
                 'www.domain1.de' => array( 
                         'GETvars' => array( 
                                 'L' => '0', 
                         ), 
                         'useConfiguration' => '_DEFAULT' 
                 ), 
                 'www.domain1.com' => array( 
                         'GETvars' => array( 
                                 'L' => '1', 
                         ), 
                         'useConfiguration' => '_DEFAULT' 
                 ), 
                 'www.domain1.gr' => array( 
                         'GETvars' => array( 
                                 'L' => '2', 
                         ), 
                         'useConfiguration' => '_DEFAULT' 
                 ), 
         ), 
); 

$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'] = array( 
         'init' => array( 
             'enableCHashCache' => '1', 
             'appendMissingSlash' => 'ifNotFile,redirect', 
             'adminJumpToBackend' => '1', 
             'enableUrlDecodeCache' => '1', 
             'enableUrlEncodeCache' => '1', 
             'emptyUrlReturnValue' => '/', 
             'respectSimulateStaticURLs' => '1', 
             'disableErrorLog' => '1', 
         ), 
         'pagePath' => array( 
      				'type' => 'user',
      				'userFunc' => 'EXT:realurl/class.tx_realurl_advanced.php:&tx_realurl_advanced->main',
      				'spaceCharacter' => '-',
      				'languageGetVar' => 'L',
      				'expireDays' => 7,
      				'firstHitPathCache' => 1, 		
              'rootpage_id' => $RootPID[$_SERVER['HTTP_HOST']],	
         ), 
      	 'fileName' => array(
      			...........
      	 ),
         'preVars' => array( 
             '0' => array( 
                 'GETvar' => 'L', 
                 'valueMap' => array( 
                     'gr' => '2', 
                     'en' => '1', 
                 ), 
                 'noMatch' => 'bypass', 
             ), 
         ), 
    		 'postVarSets' => array(
    				'_DEFAULT' => array(
             ...........      
    		    ),
    		 ),
); 
?>

Wie kann ich hier definieren, dass das array _DOMAINS nur für die domain1 bestimmt ist? Denn derzeit wäre es so, dass die domain2 auch die domain1-url vorangestellt bekommt, da die Sprachparameter die gleichen sind.

Viele Grüße