Modules: Release of xlanguage 3.0
Posted by: phpppOn 2006/7/8 13:47:15 26855 readsxlanguage, eXtensible Xoops Multilingual Content and Encoding Management
it works with all active XOOPS versions and any version of any MODULE with any THEME by inersting one line code to common.php, no need of hack to XOOPS core and modules.
Download xlanguage 3.0
Mirror at Sourceforge
xlanguage 3.0 changelog: 1 compatable for all Xoops active versions 2 added smarty template for block 3 added inline scripts for displaying language switch manner anywhere prefered User guide ---------- 1 install "xlanguage" as a regular module 2 insert one line
include_once XOOPS_ROOT_PATH.'/modules/xlanguage/api.php';
// #################### Include site-wide lang file ##################
if ( file_exists(XOOPS_ROOT_PATH."/language/".$xoopsConfig['language']."/global.php") ) {
include_once XOOPS_ROOT_PATH."/language/".$xoopsConfig['language']."/global.php";
} else {
include_once XOOPS_ROOT_PATH."/language/english/global.php";
}
//%%%%% LANGUAGE SPECIFIC SETTINGS %%%%%
//define('_CHARSET', 'GB2312');
//define('_LANGCODE', 'zh-CN');
define('_CHARSET', empty($xlanguage["charset"])?'GB2312':$xlanguage["charset"]);
define('_LANGCODE', empty($xlanguage["code"])?'zh-CN':$xlanguage["code"]);
$xlanguage['charset_base'] = "gb2312";