Hi PMS,
Thank you, ok here is some information:
Versions:
ModX
1.0.2
YAMS
1.1.7 Alpha RC7
ManagerManager
0.3.6
yams.config.inc.php:
<?php
// The ids of the active languages
$this->itsActiveLangIds = array(
'en'
, 'fr'
, 'de'
, 'nl'
);
// The ids of the inactive languages
$this->itsInactiveLangIds = array(
);
// The language direction (ltr or rtl)
$this->itsIsLTR = array(
'en' => TRUE
, 'fr' => TRUE
, 'de' => TRUE
, 'nl' => TRUE
);
// The default language id
$this->itsDefaultLangId = 'en';
// The name of the root folder
$this->itsRootName = array(
'en' => 'en'
, 'fr' => 'fr'
, 'de' => 'de'
, 'nl' => 'nl'
);
// The monolingual page server name
$this->itsMonoServerName = '';
// The server name for each language
$this->itsMultiServerName = array(
'en' => ''
, 'fr' => ''
, 'de' => ''
, 'nl' => ''
);
// The name of each language in all languages
$this->itsLangNames = array(
'en' => array(
'en' => 'English'
, 'fr' => '(French)'
, 'ja' => '(Japanese)'
, 'de' => '(German)'
, 'ru' => '(Russian)'
)
, 'fr' => array(
'en' => '(Anglais)'
, 'fr' => 'Français'
, 'ja' => '(Japonais)'
, 'de' => '(Allemand)'
, 'ru' => '(Russe)'
)
, 'de' => array(
'en' => '(Englisch)'
, 'fr' => '(Französisch)'
, 'ja' => '(Japanisch)'
, 'de' => 'Deutsch'
, 'ru' => '(Russisch)'
)
, 'nl' => array(
'en' => '(Engels)'
, 'fr' => '(Frans)'
, 'de' => '(Duits)'
, 'nl' => 'Nederlands'
)
);
$this->itsChooseLangText = array(
'en' => 'Select language'
, 'fr' => 'Choisir une langue'
, 'de' => 'Waehle Sprache'
, 'nl' => 'Kies taal'
);
// The languages that should be directed to this language root.
// These should be in priority order
// The tag is in the format provided by the HTTP Accept-Language header:
// xx, or xx-yy, where
// xx: is a two letter language abbreviation
// http://www.loc.gov/standards/iso639-2/php/code_list.php
// yy: is a two letter country code
// http://www.iso.org/country_codes/iso_3166_code_lists/english_country_names_and_code_elements.htm
// xx on its own matches an xx Accept-Language header
// with any country code
// At least one language tag must be specified.
$this->itsLangTags = array(
'en' => array(
'en'
)
, 'fr' => array(
'fr'
)
, 'de' => array(
'de'
)
, 'nl' => array(
'nl'
)
);
// The MODx manager language name for each language group.
$this->itsMODxLangName = array(
'en' => 'english'
, 'fr' => 'francais-utf8'
, 'de' => 'german'
, 'nl' => 'nederlands-utf8'
);
// The encoding modifier.
// 'manager' means use the manager setting
// 'u' if webpage content is in UTF-8
// '' otherwise
$this->itsEncodingModifierMode = 'manager';
// a comma separated list of active template ids
// if the default activity is none
$this->itsActiveTemplates = array(
4 => NULL
);
// Whether or not to manage template variables automatically
$this->itsManageTVs = TRUE;
// The yams current lang query parameter name
$this->itsLangQueryParam = 'yams_lang';
// The yams change lang query parameter name
$this->itsChangeLangQueryParam = 'yams_new_lang';
// Turn on/off redirection from existing pages to multilingual pages
// You can set to false if you are developing a site from scratch
// - although leaving as TRUE does not harm in this instance
// Set to TRUE if you are converting a website
// that has already been made public
$this->itsRedirectionMode = 'default';
// The type of http redirection to perform when redirecting to the default language
$this->itsHTTPStatus = 307;
// The type of http redirection to perform when redirecting to a non-default language
$this->itsHTTPStatusNotDefault = 303;
// The type of http redirection to perform when responding to a request to change language
$this->itsHTTPStatusChangeLang = 303;
// Whether or not to hide the original fields
$this->itsHideFields = FALSE;
// Whether or not to place tvs for individual languages on separate tabs
$this->itsTabifyLangs = TRUE;
// Whether or not to synchronise the document pagetitle with the default language pagetitle
$this->itsSynchronisePagetitle = FALSE;
// Whether or not to to use EasyLingual Compatiblity Mode
$this->itsEasyLingualCompatibility = FALSE;
// Whether or not to show the site_start document alias.
$this->itsShowSiteStartAlias = TRUE;
// Whether or not to rewrite containers as folders.
$this->itsRewriteContainersAsFolders = FALSE;
// If MODx is installed into a subdirectory then this param
// can be used to specify the path to that directory.
// (with a trailing slash and no leading slash)
$this->itsMODxSubdirectory = 'modx';
// The URL conversion mode
// none: Don't do any automatic conversion of MODx URLs.
// default: Convert MODx URLs surrounded by double quotes to (yams_doc:id) placeholders
// resolve: Convert MODx URLs surrounded by double quotes to (yams_docr:id) placeholders
$this->itsURLConversionMode = 'default';
// Whether or not to use multilingual aliases.
$this->itsUseMultilingualAliases = TRUE;
// Whether or not multilingual aliases are unique.
$this->itsMultilingualAliasesAreUnique = TRUE;
// Whether or not to use mime-dependent URL suffixes.
$this->itsUseMimeDependentSuffixes = FALSE;
// The mime-type to suffix mapping.
$this->itsMimeSuffixMap = array(
'application/xhtml+xml' => '.xhtml'
, 'application/javascript' => '.js'
, 'text/javascript' => '.js'
, 'application/rss+xml' => '.rss'
, 'application/xml' => '.xml'
, 'text/xml' => '.xml'
, 'text/css' => '.css'
, 'text/html' => '.html'
, 'text/plain' => '.txt'
);
// Whether or not to use stripAlias on multilingual aliases.
$this->itsUseStripAlias = TRUE;
// An array of doc ids for which URLs of the form index.php?id= ... will be // accepted - even if friendly aliases are being used.
// A * entry means all docIds.
$this->itsAcceptMODxURLDocIds = array(
'*'
);
?>
Server config:
You can use the following text to replace the friendly URLs sections of your MODx .htaccess file.
# Friendly URLs
RewriteEngine On
RewriteBase /modx/
# Fix Apache internal dummy connections from breaking [(site_url)] cache
RewriteCond %{HTTP_USER_AGENT} ^.*internal\ dummy\ connection.*$ [NC]
RewriteRule .* - [F,L]
# Exclude /assets and /manager directories from rewrite rules
RewriteRule ^(manager|assets) - [L]
# Redirect from mydomain.com/rootname to mydomain.com/rootname/
RewriteRule ^en$ en/ [R=301,L]
RewriteRule ^fr$ fr/ [R=301,L]
RewriteRule ^de$ de/ [R=301,L]
RewriteRule ^nl$ nl/ [R=301,L]
# The Friendly URLs part
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^nl/(.*)$ index.php?q=$1 [L,QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^en/(.*)$ index.php?q=$1 [L,QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^de/(.*)$ index.php?q=$1 [L,QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^fr/(.*)$ index.php?q=$1 [L,QSA]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?q=$1 [L,QSA]
Language settings are kindof default:
* Language dependent server name mode is currently OFF. To enable this mode you need to specify a monolingual server name and a multilingual server name for each active language.
* Language dependent root name mode is currently ON. To disable this mode you need to clear all root names.
* Unique multilingual aliases mode is currently ON. YAMS can determine the document id and language from the alias alone, so it is not necessary to specify root names or server names.
* Query param mode is currently OFF. The language can be determined from the server and root names alone. No additional query param is required.
Monolingual Settings Help Action/Name Edit
The server name to use for non-multilingual pages. Leave the field blank to accept the default server name, in which case the current server name will be shown in brackets. Server Name (localhost)
The site URL for monolingual pages. Site URL http://localhost/modx/
Multilingual Settings Help Action/Name Edit Edit Edit Edit Add
Deactivate Deactivate Deactivate
Is Default Set Default Set Default Set Default
Help Action/Name Edit Edit Edit Edit Add
Deactivate Deactivate Deactivate
Is Default Set Default Set Default Set Default
An identifier for this language group. Alphanumeric characters, no spaces. Lang ID en fr de nl
A comma separated list of language tags, in priority order, to be associated with this language group. eg: en-us,en-gb Tags en fr de nl
The server/host name associated with the language group. Leave the field blank to accept the default server name, in which case the current server name will be shown in brackets. Server Name (localhost) (localhost) (localhost) (localhost)
A root folder name to be used with the language group. Leave empty if you don’t which to distinguish language groups by folder. Root Name en fr de nl
The site url for the language group. Formed from the server name and root name. Each language must have a unique site url. This parameter can be accessed using the (yams_site) placeholder. Site URL http://localhost/modx/en/ http://localhost/modx/fr/ http://localhost/modx/de/ http://localhost/modx/nl/
The language direction. This parameter can be accessed using (yams_dir). Language direction ltr ltr ltr ltr
The corresponding MODx manager language. For use with snippets like ditto and eForm which accept a language parameter. MODx Language Name english francais-utf8 german nederlands-utf8
Text, written in the current language, to be used when presenting the user with a choice of languages. Select Language Text Select language Choisir une langue Waehle Sprache Kies taal
The name to use for the language group en written in the current language. Name for en English (Anglais) (Englisch) (Engels)
The name to use for the language group fr written in the current language. Name for fr (French) Français (Französisch) (Frans)
The name to use for the language group de written in the current language. Name for de (German) (Allemand) Deutsch (Duits)
The name to use for the language group nl written in the current language. Name for nl Nederlands
The name to use for the new language group in its own language. Used only when adding a new language. Name for new
http://img17.imageshack.us/img17/3747/multilingualtemplates.jpg
http://img13.imageshack.us/img13/5931/otherparams.jpg
Let me know if you need something more and thanks for your help.
Kinds Regards, Joey