phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] CVS: setup lang.php,1.41,1.42


From: Ralf Becker <address@hidden>
Subject: [Phpgroupware-cvs] CVS: setup lang.php,1.41,1.42
Date: Fri, 18 Oct 2002 10:44:38 -0400

Update of /cvsroot/phpgroupware/setup
In directory subversions:/tmp/cvs-serv28519

Modified Files:
        lang.php 
Log Message:
some fixes to get manage languages working again:
- fixed table-names for 'lang' to 'phpgw_lang' and 'languages' to 
'phpgw_languages'
- changed calls to function in setup_detection and setup_html to use 
$GLOBALS['phpgw_setup']->html / detection

Index: lang.php
===================================================================
RCS file: /cvsroot/phpgroupware/setup/lang.php,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** lang.php    17 Sep 2002 04:24:14 -0000      1.41
--- lang.php    18 Oct 2002 14:44:10 -0000      1.42
***************
*** 52,56 ****
                        if ($upgrademethod == 'dumpold')
                        {
!                               $GLOBALS['phpgw_setup']->db->query("DELETE FROM 
lang",__LINE__,__FILE__);
                                //echo '<br>Test: dumpold';
                        }
--- 52,56 ----
                        if ($upgrademethod == 'dumpold')
                        {
!                               $GLOBALS['phpgw_setup']->db->query("DELETE FROM 
phpgw_lang",__LINE__,__FILE__);
                                //echo '<br>Test: dumpold';
                        }
***************
*** 61,66 ****
                                if ($upgrademethod == 'addonlynew')
                                {
!                                       //echo "<br>Test: addonlynew - select 
count(*) from lang where lang='".$lang."'";
!                                       
$GLOBALS['phpgw_setup']->db->query("SELECT COUNT(*) FROM lang WHERE 
lang='".$lang."'",__LINE__,__FILE__);
                                        
$GLOBALS['phpgw_setup']->db->next_record();
  
--- 61,66 ----
                                if ($upgrademethod == 'addonlynew')
                                {
!                                       //echo "<br>Test: addonlynew - select 
count(*) from phpgw_lang where lang='".$lang."'";
!                                       
$GLOBALS['phpgw_setup']->db->query("SELECT COUNT(*) FROM phpgw_lang WHERE 
lang='".$lang."'",__LINE__,__FILE__);
                                        
$GLOBALS['phpgw_setup']->db->next_record();
  
***************
*** 74,79 ****
                                {
                                        //echo '<br>Test: loop above file()';
!                                       $setup_info = 
$GLOBALS['phpgw_setup']->get_versions();
!                                       $setup_info = 
$GLOBALS['phpgw_setup']->get_db_versions($setup_info);
                                        $raw = $raw_file = array();
                                        // Visit each app/setup dir, look for a 
lang file
--- 74,79 ----
                                {
                                        //echo '<br>Test: loop above file()';
!                                       $setup_info = 
$GLOBALS['phpgw_setup']->detection->get_versions();
!                                       $setup_info = 
$GLOBALS['phpgw_setup']->detection->get_db_versions($setup_info);
                                        $raw = $raw_file = array();
                                        // Visit each app/setup dir, look for a 
lang file
***************
*** 103,107 ****
                                                        {
                                                                //echo 
'<br>Test: addmissing';
!                                                               
$GLOBALS['phpgw_setup']->db->query("SELECT COUNT(*) FROM lang WHERE 
message_id='".$message_id."' and lang='".$GLOBALS['phpgw_setup']->db_lang."' 
and (app_name='".$app_name."' or app_name='common')",__LINE__,__FILE__);
                                                                
$GLOBALS['phpgw_setup']->db->next_record();
  
--- 103,107 ----
                                                        {
                                                                //echo 
'<br>Test: addmissing';
!                                                               
$GLOBALS['phpgw_setup']->db->query("SELECT COUNT(*) FROM phpgw_lang WHERE 
message_id='".$message_id."' and lang='".$GLOBALS['phpgw_setup']->db_lang."' 
and (app_name='".$app_name."' or app_name='common')",__LINE__,__FILE__);
                                                                
$GLOBALS['phpgw_setup']->db->next_record();
  
***************
*** 118,125 ****
                                                                {
                                                                        //echo 
"<br>adding - insert into lang values 
('".$message_id."','".$app_name."','".$GLOBALS['phpgw_setup']->db_lang."','".$content."')";
!                                                                       $result 
= $GLOBALS['phpgw_setup']->db->query("INSERT INTO 
lang(message_id,app_name,lang,content) 
VALUES('".$message_id."','".$app_name."','".$GLOBALS['phpgw_setup']->db_lang."','".$content."')",__LINE__,__FILE__);
                                                                        if 
(intval($result) <= 0)
                                                                        {
!                                                                               
echo "<br>Error inserting record: lang values 
('".$message_id."','".$app_name."','".$GLOBALS['phpgw_setup']->db_lang."','".$content."')";
                                                                        }
                                                                }
--- 118,125 ----
                                                                {
                                                                        //echo 
"<br>adding - insert into lang values 
('".$message_id."','".$app_name."','".$GLOBALS['phpgw_setup']->db_lang."','".$content."')";
!                                                                       $result 
= $GLOBALS['phpgw_setup']->db->query("INSERT INTO 
phpgw_lang(message_id,app_name,lang,content) 
VALUES('".$message_id."','".$app_name."','".$GLOBALS['phpgw_setup']->db_lang."','".$content."')",__LINE__,__FILE__);
                                                                        if 
(intval($result) <= 0)
                                                                        {
!                                                                               
echo "<br>Error inserting record: phpgw_lang values 
('".$message_id."','".$app_name."','".$GLOBALS['phpgw_setup']->db_lang."','".$content."')";
                                                                        }
                                                                }
***************
*** 148,152 ****
                if (!$included)
                {
!                       $tpl_root = 
$GLOBALS['phpgw_setup']->setup_tpl_dir('setup');
                        $setup_tpl = 
CreateObject('phpgwapi.Template',$tpl_root);
                        $setup_tpl->set_file(array(
--- 148,152 ----
                if (!$included)
                {
!                       $tpl_root = 
$GLOBALS['phpgw_setup']->html->setup_tpl_dir('setup');
                        $setup_tpl = 
CreateObject('phpgwapi.Template',$tpl_root);
                        $setup_tpl->set_file(array(
***************
*** 168,172 ****
                        $select_box_desc = lang('Select which languages you 
would like to use');
                        $select_box = '';
!                       $GLOBALS['phpgw_setup']->db->query("select 
lang_id,lang_name from languages where available='Yes'");
                        while ($GLOBALS['phpgw_setup']->db->next_record())
                        {
--- 168,172 ----
                        $select_box_desc = lang('Select which languages you 
would like to use');
                        $select_box = '';
!                       $GLOBALS['phpgw_setup']->db->query("select 
lang_id,lang_name from phpgw_languages where available='Yes'");
                        while ($GLOBALS['phpgw_setup']->db->next_record())
                        {
***************
*** 209,215 ****
  
                        $ConfigDomain = 
$GLOBALS['HTTP_COOKIE_VARS']['ConfigDomain'] ? 
$GLOBALS['HTTP_COOKIE_VARS']['ConfigDomain'] : 
$GLOBALS['HTTP_POST_VARS']['ConfigDomain'];
!                       
$GLOBALS['phpgw_setup']->show_header("$stage_title",False,'config',$ConfigDomain
 . '(' . $phpgw_domain[$ConfigDomain]['db_type'] . ')');
                        $setup_tpl->pparse('out','T_lang_main');
!                       $GLOBALS['phpgw_setup']->show_footer();
                }
        }
--- 209,215 ----
  
                        $ConfigDomain = 
$GLOBALS['HTTP_COOKIE_VARS']['ConfigDomain'] ? 
$GLOBALS['HTTP_COOKIE_VARS']['ConfigDomain'] : 
$GLOBALS['HTTP_POST_VARS']['ConfigDomain'];
!                       
$GLOBALS['phpgw_setup']->html->show_header("$stage_title",False,'config',$ConfigDomain
 . '(' . $phpgw_domain[$ConfigDomain]['db_type'] . ')');
                        $setup_tpl->pparse('out','T_lang_main');
!                       $GLOBALS['phpgw_setup']->html->show_footer();
                }
        }





reply via email to

[Prev in Thread] Current Thread [Next in Thread]