Index: /trunk/install.php
===================================================================
--- /trunk/install.php	(revision 5982)
+++ /trunk/install.php	(revision 5983)
@@ -147,29 +147,6 @@
 $errors = array();
 
-// database config file migration : mysql.inc.php et database.inc.php
-$old_config_file = PHPWG_ROOT_PATH . 'include/mysql.inc.php';
 $config_file = PHPWG_ROOT_PATH . 'local/config/database.inc.php';
-if (!file_exists($config_file) && file_exists($old_config_file))
-{
-  $step = 3;
-  include $old_config_file;
-  $file_content = '<?php
-$conf[\'dblayer\'] = \'mysql\';
-$conf[\'db_base\'] = \''.$cfgBase.'\';
-$conf[\'db_user\'] = \''.$cfgUser.'\';
-$conf[\'db_password\'] = \''.$cfgPassword.'\';
-$conf[\'db_host\'] = \''.$cfgHote.'\';
-
-$prefixeTable = \''.$prefixeTable.'\';
-
-define(\'PHPWG_INSTALLED\', true);
-define(\'PWG_CHARSET\', \''.PWG_CHARSET.'\');
-define(\'DB_CHARSET\', \''.DB_CHARSET.'\');
-define(\'DB_COLLATE\', \''.DB_COLLATE.'\');
-
-?'.'>';
-}
-// Open config.php ... if it exists
-elseif (@file_exists($config_file))
+if (@file_exists($config_file))
 {
   include($config_file);
@@ -235,10 +212,8 @@
 define('PHPWG_URL', 'http://'.PHPWG_DOMAIN);
 
-if (empty($step) || ($step != 3))
-{
-  load_language('common.lang', '', array('language' => $language, 'target_charset'=>'utf-8'));
-  load_language('admin.lang', '', array('language' => $language, 'target_charset'=>'utf-8'));
-  load_language('install.lang', '', array('language' => $language, 'target_charset'=>'utf-8'));
-}
+load_language('common.lang', '', array('language' => $language, 'target_charset'=>'utf-8'));
+load_language('admin.lang', '', array('language' => $language, 'target_charset'=>'utf-8'));
+load_language('install.lang', '', array('language' => $language, 'target_charset'=>'utf-8'));
+
 header('Content-Type: text/html; charset=UTF-8');
 //------------------------------------------------- check php version
@@ -408,64 +383,31 @@
 
 //------------------------------------------------------ start template output
-if ($step == 3)
-{
-  @umask(0111);
-  // writing the new configuration file
-  if ( !($fp = @fopen( $config_file, 'w' )))
-  {
-    $html_content = htmlentities( $file_content, ENT_QUOTES );
-    $html_content = nl2br( $html_content );
-    
-    $error_copy = l10n('An alternate solution is to copy the text in the box above and paste it into the file "local/config/database.inc.php" (Warning : database.inc.php must only contain what is in the textarea, no line return or space character)');
-    $error_copy .= '<br><br>';
-    $error_copy .= '<textarea rows="15" cols="70">'.$html_content.'</textarea>';
-  } 
-  else 
-  {
-    @fputs($fp, $file_content, strlen($file_content));
-    @fclose($fp);
-
-    @unlink($old_config_file);
-    header("Location: index.php");
-    exit();
-  }
-
-  $template->assign(
-    array(
-      'T_CONTENT_ENCODING' => 'utf-8',
-      'migration' => true
-      )
-    );
-}
-else
-{
-  $dbengines = available_engines();
-
-  foreach ($languages->fs_languages as $language_code => $language_name)
-  {
-    if ($language == $language_code)
-    {
-      $template->assign('language_selection', $language_code);
-    }
-    $languages_options[$language_code] = $language_name;
-  }
-  $template->assign('language_options', $languages_options);
-
-  $template->assign(
-    array(
-      'T_CONTENT_ENCODING' => 'utf-8',
-      'RELEASE' => PHPWG_VERSION,
-      'F_ACTION' => 'install.php?language=' . $language,
-      'F_DB_ENGINES' => $dbengines,
-      'F_DB_LAYER' => $dblayer,
-      'F_DB_HOST' => $dbhost,
-      'F_DB_USER' => $dbuser,
-      'F_DB_NAME' => $dbname,
-      'F_DB_PREFIX' => $prefixeTable,
-      'F_ADMIN' => $admin_name,
-      'F_ADMIN_EMAIL' => $admin_mail,
-      'L_INSTALL_HELP' => sprintf(l10n('Need help ? Ask your question on <a href="%s">Piwigo message board</a>.'), PHPWG_URL.'/forum'),
-      ));
-}
+$dbengines = available_engines();
+
+foreach ($languages->fs_languages as $language_code => $language_name)
+{
+  if ($language == $language_code)
+  {
+    $template->assign('language_selection', $language_code);
+  }
+  $languages_options[$language_code] = $language_name;
+}
+$template->assign('language_options', $languages_options);
+
+$template->assign(
+  array(
+    'T_CONTENT_ENCODING' => 'utf-8',
+    'RELEASE' => PHPWG_VERSION,
+    'F_ACTION' => 'install.php?language=' . $language,
+    'F_DB_ENGINES' => $dbengines,
+    'F_DB_LAYER' => $dblayer,
+    'F_DB_HOST' => $dbhost,
+    'F_DB_USER' => $dbuser,
+    'F_DB_NAME' => $dbname,
+    'F_DB_PREFIX' => $prefixeTable,
+    'F_ADMIN' => $admin_name,
+    'F_ADMIN_EMAIL' => $admin_mail,
+    'L_INSTALL_HELP' => sprintf(l10n('Need help ? Ask your question on <a href="%s">Piwigo message board</a>.'), PHPWG_URL.'/forum'),
+    ));
 
 //------------------------------------------------------ errors & infos display
@@ -473,11 +415,4 @@
 {
   $template->assign('install', true);
-}
-elseif ($step == 3)
-{
-  if (isset($error_copy))
-  {
-    array_push($errors, $error_copy);
-  }
 }
 else
