redray
2008-11-30 00dfbafa919e12b7fb4fb869b273ec724e0ade07
install/lib/installer_base.lib.php
@@ -119,7 +119,7 @@
      
      $cf = $conf['mysql']; // make $conf['mysql'] more accessible
      //** Create the database
      if(!$this->db->query('CREATE DATABASE IF NOT EXISTS '.$cf['database'])) {
      if(!$this->db->query('CREATE DATABASE IF NOT EXISTS '.$cf['database'].' DEFAULT CHARACTER SET '.$cf['charset'])) {
         $this->error('Unable to create MySQL database: '.$cf['database'].'.');
      }
      
@@ -132,10 +132,10 @@
         $this->error('Stopped: Database already contains some tables.');
      } else {
         if($cf['admin_password'] == '') {
            caselog("mysql -h '".$cf['host']."' -u '".$cf['admin_user']."' '".$cf['database']."' < '".ISPC_INSTALL_ROOT."/install/sql/ispconfig3.sql' &> /dev/null",
            caselog("mysql --default-character-set=".$cf['charset']." -h '".$cf['host']."' -u '".$cf['admin_user']."' '".$cf['database']."' < '".ISPC_INSTALL_ROOT."/install/sql/ispconfig3.sql' &> /dev/null",
                        __FILE__, __LINE__, 'read in ispconfig3.sql', 'could not read in ispconfig3.sql');
         } else {
            caselog("mysql -h '".$cf['host']."' -u '".$cf['admin_user']."' -p'".$cf['admin_password']."' '".$cf['database']."' < '".ISPC_INSTALL_ROOT."/install/sql/ispconfig3.sql' &> /dev/null",
            caselog("mysql --default-character-set=".$cf['charset']." -h '".$cf['host']."' -u '".$cf['admin_user']."' -p'".$cf['admin_password']."' '".$cf['database']."' < '".ISPC_INSTALL_ROOT."/install/sql/ispconfig3.sql' &> /dev/null",
                        __FILE__, __LINE__, 'read in ispconfig3.sql', 'could not read in ispconfig3.sql');
         }
         $db_tables = $this->db->getTables();