From b8b71e4e4920dd788974bba8f984d267a4d8287b Mon Sep 17 00:00:00 2001 From: Max Kremmel Date: Sun, 17 Jul 2005 17:36:08 +0000 Subject: Merge recent changes from R1 to HEAD - never doing this again. --- BitLanguage.php | 6 +++++- admin/schema_inc.php | 4 ++-- import.php | 4 ++-- templates/babelfish.tpl | 8 ++++---- 4 files changed, 13 insertions(+), 9 deletions(-) diff --git a/BitLanguage.php b/BitLanguage.php index ac3ab6b..df6c093 100644 --- a/BitLanguage.php +++ b/BitLanguage.php @@ -14,7 +14,7 @@ // +----------------------------------------------------------------------+ // | Authors: spider // +----------------------------------------------------------------------+ -// $Id: BitLanguage.php,v 1.3 2005/06/21 17:02:21 spiderr Exp $ +// $Id: BitLanguage.php,v 1.4 2005/07/17 17:36:07 squareing Exp $ class BitLanguage extends BitBase { // list of available (non-disabled) languages @@ -54,6 +54,10 @@ class BitLanguage extends BitBase { } } + function getLanguage() { + return( $this->mLanguage ); + } + function setLanguage( $pLangCode ) { $this->mLanguage = $pLangCode; } diff --git a/admin/schema_inc.php b/admin/schema_inc.php index ff6dc9b..21fa9c6 100644 --- a/admin/schema_inc.php +++ b/admin/schema_inc.php @@ -33,7 +33,7 @@ $tables = array( global $gBitInstaller; foreach( array_keys( $tables ) AS $tableName ) { - $gBitInstaller->registerSchemaTable( LANGUAGES_PKG_DIR, $tableName, $tables[$tableName], TRUE ); + $gBitInstaller->registerSchemaTable( LANGUAGES_PKG_NAME, $tableName, $tables[$tableName], TRUE ); } $indices = array ( @@ -46,7 +46,7 @@ $indices = array ( 'tiki_i18n_version_ver_idx' => array( 'table' => 'tiki_i18n_version_map', 'cols' => '`version`', 'opts' => NULL ), ); -$gBitInstaller->registerSchemaIndexes( LANGUAGES_PKG_DIR, $indices ); +$gBitInstaller->registerSchemaIndexes( LANGUAGES_PKG_NAME, $indices ); $gBitInstaller->registerPackageInfo( LANGUAGES_PKG_NAME, array( 'description' => "This package allows you to translate your site into a different language.", diff --git a/import.php b/import.php index 82beb51..ce8bc59 100644 --- a/import.php +++ b/import.php @@ -1,6 +1,6 @@ mStrings); foreach( $gBitLanguage->mStrings[$_REQUEST['export_lang_code']] as $tran ) { - if( !empty( $_REQUEST['all_trans'] ) || ($tran['version'] == BITWEAVER_BRANCH && !empty( $tran['tran'] ) ) ) { + if( !empty( $_REQUEST['all_trans'] ) || ($tran['version'] == BIT_MAJOR_VERSION && !empty( $tran['tran'] ) ) ) { $data .= "'" . str_replace( "'", "\\'", stripslashes( $tran["source"] ) ) . "' => '" . str_replace( "'", "\\'",stripslashes( $tran["tran"] ) ) . "',\n"; } } diff --git a/templates/babelfish.tpl b/templates/babelfish.tpl index 1d814a4..98d1f53 100644 --- a/templates/babelfish.tpl +++ b/templates/babelfish.tpl @@ -1,6 +1,6 @@ -{* $Header: /cvsroot/bitweaver/_bit_languages/templates/babelfish.tpl,v 1.1 2005/06/19 04:55:13 bitweaver Exp $ *} +{* $Header: /cvsroot/bitweaver/_bit_languages/templates/babelfish.tpl,v 1.2 2005/07/17 17:36:08 squareing Exp $ *} -{if $gBitSystemPrefs.feature_babelfish eq 'y' and $gBitSystemPrefs.feature_babelfish_logo eq 'y'} +{if $gBitSystem->isFeatureActive( 'feature_babelfish' ) and $gBitSystem->isFeatureActive( 'feature_babelfish_logo' )}
@@ -23,7 +23,7 @@
-{elseif $gBitSystemPrefs.feature_babelfish eq 'y' and $gBitSystemPrefs.feature_babelfish_logo eq 'n'} +{elseif $gBitSystem->isFeatureActive( 'feature_babelfish' ) and !$gBitSystemPrefs->isFeatureActive( 'feature_babelfish_logo' )}
@@ -35,7 +35,7 @@
-{elseif $gBitSystemPrefs.feature_babelfish eq 'n' and $gBitSystemPrefs.feature_babelfish_logo eq 'y'} +{elseif !$gBitSystem->isFeatureActive( 'feature_babelfish' ) and $gBitSystemPrefs->isFeatureActive( 'feature_babelfish_logo' )}
{$babelfish_logo} -- cgit v1.3