Hi.
Habe jetzt schon ewig rum gemacht und Foren gewälzt aber komme zu keiner Lösung. #angry#
Ich habe:
1 Typo3 Installation in der verschiedene 2 Projekte laufen. Diese werden per Domain im Typo3 unterschieden.
Das 1. Projekt hat 3 Sprachen das 2. 1 Sprache.
Normalerweise läufen beide Domains ohne Unterverzeichnis. Ich habe aber zum testen einen Server der unter www.domain1.de/dev/ läuft.
Für beide Seitenstränge habe ich config.baseURL gesetzt.
Und möchte:
Das der Langparameter richtig übersetzt wird.
RealUrl läuft sonst einwandfrei aber er parst eben das &l=1 nicht in /en/.
Wenn ich von Hand www.domain1.de/dev/en/ eingeben leitet er mich auf www.domain1.de/dev/ weiter?
D.h. die URLs sollen nicht so
-> www.domain1.de/unternehmen.html&L=1 heißen
sondern
-> www.domain1.de/en/unternehmen.html
oder
-> www.domain1.de/en/company.html heißen
So sieht meine localconf aus.
<?php
$TYPO3_CONF_VARS['EXTCONF']['realurl'] = array(
'_DEFAULT' => array(
'init' => array(
'enableCHashCache' => 1,
'appendMissingSlash' => 'ifNotFile',
'enableUrlDecodeCache' => 1,
'enableUrlEncodeCache' => 1,
'respectSimulateStaticURLs' => 0,
'postVarSet_failureMode'=>'redirect_goodUpperDir',
),
'redirects_regex' => array (
),
'preVars' => array(
array(
'GETvar' => 'no_cache',
'valueMap' => array(
'no_cache' => 1,
),
'noMatch' => 'bypass',
),
array(
'GETvar' => 'L',
'valueMap' => array(
'de' => '0',
'en' => '1',
'si' => '3',
'valueDefault' => 'de',
),
'noMatch' => 'bypass',
'GETvar' => 'print',
'valueMap' => array(
'print' => '1',
),
'noMatch' => 'bypass',
),
),
'pagePath' => array(
'type' => 'user',
'userFunc' => 'EXT:realurl/class.tx_realurl_advanced.php:&tx_realurl_advanced->main',
'spaceCharacter' => '-',
'languageGetVar' => 'L',
'expireDays' => 7,
'rootpage_id' => 1,
),
'postVarSets' => array(
'_DEFAULT' => array(
// news archive parameters
'archive' => array(
array(
'GETvar' => 'tx_ttnews[year]' ,
),
array(
'GETvar' => 'tx_ttnews[month]' ,
'valueMap' => array(
'january' => '01',
'february' => '02',
'march' => '03',
'april' => '04',
'may' => '05',
'june' => '06',
'july' => '07',
'august' => '08',
'september' => '09',
'october' => '10',
'november' => '11',
'december' => '12',
)
),
),
// news pagebrowser
'browse' => array(
array(
'GETvar' => 'tx_ttnews[pointer]',
),
),
// news categories
'select_category' => array (
array(
'GETvar' => 'tx_ttnews[cat]',
),
),
// news articles and searchwords
'article' => array(
array(
'GETvar' => 'tx_ttnews[tt_news]',
'lookUpTable' => array(
'table' => 'tt_news',
'id_field' => 'uid',
'alias_field' => 'title',
'addWhereClause' => ' AND NOT deleted',
'useUniqueCache' => 1,
'useUniqueCache_conf' => array(
'strtolower' => 1,
'spaceCharacter' => '-',
),
),
),
array(
'GETvar' => 'tx_ttnews[swords]',
),
),
// backPID
'backPID' => array(
array(
'GETvar' => 'tx_ttproducts_pi1[backPID]',
'lookUpTable' => array(
'table' => 'pages',
'id_field' => 'uid',
'alias_field' => 'title',
'addWhereClause' => ' AND NOT deleted',
'useUniqueCache' => 1,
'useUniqueCache_conf' => array(
'strtolower' => 1,
'spaceCharacter' => '-',
),
),
),
),
// product categories
'categories' => array(
array(
'GETvar' => 'tx_ttproducts_pi1[cat]',
'lookUpTable' => array(
'table' => 'tt_products_cat',
'id_field' => 'uid',
'alias_field' => 'title',
'addWhereClause' => ' AND NOT deleted',
'useUniqueCache' => 1,
'useUniqueCache_conf' => array(
'strtolower' => 1,
'spaceCharacter' => '-',
),
),
),
),
// products
'products' => array(
array(
'GETvar' => 'tx_ttproducts_pi1[product]',
'lookUpTable' => array(
'table' => 'tt_products',
'id_field' => 'uid',
'alias_field' => 'title',
'addWhereClause' => ' AND NOT deleted',
'useUniqueCache' => 1,
'useUniqueCache_conf' => array(
'strtolower' => 1,
'spaceCharacter' => '-',
),
),
),
),
),
),
'fileName' => array(
'defaultToHTMLsuffixOnPrev'=>1,
'index' => array(
'rss.xml' => array(
'keyValues' => array(
'type' => 100,
),
),
'rss091.xml' => array(
'keyValues' => array(
'type' => 101,
),
),
'rdf.xml' => array(
'keyValues' => array(
'type' => 102,
),
),
'atom.xml' => array(
'keyValues' => array(
'type' => 103,
),
),
),
),
),
);
/***************************/
/* Für domain1 und domain2 */
/***************************/
$TYPO3_CONF_VARS['EXTCONF']['realurl']['www.domain1.de'] = $TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
$TYPO3_CONF_VARS['EXTCONF']['realurl']['www.domain1.de']['pagePath']['rootpage_id'] = 1;
$TYPO3_CONF_VARS['EXTCONF']['realurl']['www.domain2.info'] = $TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
$TYPO3_CONF_VARS['EXTCONF']['realurl']['www.domain2.info']['pagePath']['rootpage_id'] = 383;
Die htaccess hatte ich 1x so
# Enable URL rewriting
RewriteEngine On
RewriteBase /
RewriteRule ^typo3$ - [L]
RewriteRule ^typo3/.*$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule .* index.php
RewriteRule ^(.*)\.htm$ /index.php
Und 1x so
RewriteEngine On
RewriteRule ^typo3$ - [L]
RewriteRule ^typo3/.*$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule .* index.php
Meine TS-Config sieht so aus
config{
doctype = xhtml_trans
htmlTag_langKey = de
xhtml_cleaning = all
removeDefaultJS = external
doctypeSwitch = 1
## 1. Sprache Deutsch
sys_language_uid = 0
language = de
locale_all = de_DE
sys_language_mode = content_fallback
sys_language_overlay = hideNonTranslated
# Setting up the language variable "L" to be passed along with links
linkVars = L(0-3)
uniqueLinkVars = L
index_enable = 1
simulateStaticDocuments = 0
baseURL = http://www.domain1.de/dev/
tx_realurl_enable = 1
}
# Index search Deutsch
plugin.tx_indexedsearch._DEFAULT_PI_VARS.lang = 0
## 2.Sprache Englisch
[globalVar = GP:L = 1]
config.sys_language_uid = 1
config.language = en
config.locale_all = english
config.htmlTag_langKey = en
# Index search English
plugin.tx_indexedsearch._DEFAULT_PI_VARS.lang = 1
[global]
## 2.Sprache Slowenisch
[globalVar = GP:L = 3]
config.sys_language_uid = 3
config.language = si
config.locale_all = sl_SI
config.htmlTag_langKey = si
# Index search Slowenisch
plugin.tx_indexedsearch._DEFAULT_PI_VARS.lang = 3
[global]
Meine Installation:
Typo3 4.1.1
RealUrl 1.5.2
Rootserver mit Suse 10 bei 1&1
Apache/2.2.0
MySQL 5.0.18
PHP/5.1.2
Please help :o
Gruß