[TYPO3-UG Dutch] default language (L=0) lijkt te verdwijnen uit URL als ik realurl gebruik
Joost van Berckel [Content Online]
joost at contentonline.nl
Wed Dec 15 10:46:26 CET 2010
Beste Ronald,
Ik heb Eric dit al gemaild, maar zal het ook even op de nieuwsgroep
zetten. Wellicht hebben andere mensen er ook iets aan.
---
Beste Erwin,
Ik heb het destijds zo opgelost in realURL config. Ik hoop dat je er
iets aan hebt.
Let wel dat ik per taal een ander domein aanroep. Dit is trouwens goed
voor Google, want duplicate content is niet SEO vriendelijk.
Ik stuur ook even een regeltje mee (eerste regels) met preVars settings
voor languages van andere installatie.
// Pre variables
'preVars' => array(
// No cache
array(
'GETvar' => 'no_cache',
'valueMap' => array(
'no_cache' => 1,
),
'noMatch' => 'bypass',
),
///// Language (Joost original)
'1' => array (
'GETvar' => 'L',
'valueMap' => array (
'nl' => '0',
'en' => '1',
),
'noMatch' => 'bypass',
),
'2' => array (
'GETvar' => 'lang',
'valueMap' => array (
'nl' => 'nl',
'en' => 'en',
),
'noMatch' => 'bypass',
),
///// End
),
Hier volgt realURL config van perutravel.nl website (is aparte config).
Wellicht is deze config al weer achterhaald. Het is al weer wat jaartjes
geleden dat ik dit zo heb opgelost.
<?php
// Host abfragen und getVar setzen:
switch(t3lib_div::getIndpEnv('HTTP_HOST')){
case 'perutravel.nl';
$_GET['L'] = 0;
break;
case 'www.perutravel.nl';
$_GET['L'] = 0;
break;
case 'gotoperu.com';
$_GET['L'] = 2;
break;
case 'www.gotoperu.com';
$_GET['L'] = 2;
break;
case 'travesiasperu.es';
$_GET['L'] = 3;
break;
case 'www.travesiasperu.es';
$_GET['L'] = 3;
break;
// case 'perureiseburo.de';
// $_GET['L'] = 4;
// break;
// case 'www.perureiseburo.de';
// $_GET['L'] = 4;
// break;
}
// For backend charset
$TYPO3_CONF_VARS['BE']['forceCharset'] = 'utf-8';
$TYPO3_CONF_VARS['EXTCONF']['realurl'] = array(
'_DEFAULT' => array(
'init' => array(
'enableCHashCache' => 1,
'appendMissingSlash' => 'ifNotFile',
'enableUrlDecodeCache' => 1,
'enableUrlEncodeCache' => 1,
),
'preVars' => array(
array(
'GETvar' => 'L',
'valueMap' => array(),
'noMatch' => 'bypass',
),
),
'pagePath' => array(
'type' => 'user',
'userFunc' =>
'EXT:realurl/class.tx_realurl_advanced.php:&tx_realurl_advanced->main',
'spaceCharacter' => '-',
'languageGetVar' => 'L',
'expireDays' => 7,
'disablePathCache' => 0,
// 'rootpage_id' => 1,
),
'fixedPostVars' => array (
),
'postVarSets' => array (
'_DEFAULT' => array (
'archive' => array (
'0' => array (
'GETvar' => 'tx_ttnews[year]',
),
'1' => 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',
),
),
),
'browse' => array (
'0' => array (
'GETvar' => 'tx_ttnews[pointer]',
),
),
'select_category' => array (
'0' => array (
'GETvar' => 'tx_ttnews[cat]',
),
),
'article' => array (
'0' => 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' => '-',
),
),
),
'1' => array (
'GETvar' => 'tx_ttnews[swords]',
),
),
),
),
'fileName' => array (
//
// if you don't want .html-URLs set the following to "false" (e.g.
'defaultToHTMLsuffixOnPrev' => false,)
// then you get http://www.yourdomain.com/imprint/ instead of
http://www.yourdomain.com/imprint.html
//
'defaultToHTMLsuffixOnPrev' => false,
'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',
),
),
),
),
//
),
);
$TYPO3_CONF_VARS['EXTCONF']['realurl']['gotoperu.com']=
$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
$TYPO3_CONF_VARS['EXTCONF']['realurl']['www.gotoperu.com']=
$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
$TYPO3_CONF_VARS['EXTCONF']['realurl']['travesiasperu.es']=
$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
$TYPO3_CONF_VARS['EXTCONF']['realurl']['www.travesiasperu.es']=
$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
$TYPO3_CONF_VARS['EXTCONF']['realurl']['perureiseburo.de']=
$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
//$TYPO3_CONF_VARS['EXTCONF']['realurl']['www.perureiseburo.de']=
//$TYPO3_CONF_VARS['EXTCONF']['realurl']['_DEFAULT'];
?>
Succes ermee!
Je kunt me eventueel skypen via Skype naam: www.contentonline.nl
----
Met vriendelijke groeten,
Joost van Berckel
Content Online
Full service internet agency
TYPO3 consultancy and open-source solutions
Authorized Google Apps Reseller
T +31 (0)15-2160530
M +31 (0)6-55141710
F +31 (0)84-8357742
E joost at contentonline.nl
W www.contentonline.nl
Op 15-12-10 08:51, Jacco van der Post schreef:
> Hoi Ronald,
>
> In realurl moet je nog wel even de talen definieren. Kijk anders ff naar
> punt 8 en misschien naar 4 en 5.
>
> http://www.training-typo3.com/2008/12/15/typo3-multi-language/
>
> grtz Jacco
>
>
More information about the TYPO3-UG-Dutch
mailing list