Changeset 6021 for extensions/prepare21upgrade
- Timestamp:
- Apr 30, 2010, 1:44:12 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/prepare21upgrade/prep21up.php
r6014 r6021 136 136 if (is_readable($file)) 137 137 { 138 copy($file, $dir.'/local/config/database.inc.php'); 138 $file_content = '<?php 139 $conf[\'dblayer\'] = \'mysql\'; 140 $conf[\'db_base\'] = \''.$cfgBase.'\'; 141 $conf[\'db_user\'] = \''.$cfgUser.'\'; 142 $conf[\'db_password\'] = \''.$cfgPassword.'\'; 143 $conf[\'db_host\'] = \''.$cfgHote.'\'; 144 145 $prefixeTable = \''.$prefixeTable.'\'; 146 147 define(\'PHPWG_INSTALLED\', true);'; 148 if (defined('PWG_CHARSET')) 149 { 150 $file_content.= ' 151 define(\'PWG_CHARSET\', \'utf-8\'); 152 define(\'DB_CHARSET\', \'utf8\'); 153 define(\'DB_COLLATE\', \'\');'; 154 } 155 $file_content.= ' 156 ?'.'>'; 157 $new_config_file = $dir.'/local/config/database.inc.php'; 158 file_put_contents($new_config_file, $file_content); 159 @chmod($new_config_file, 0777); 139 160 } 140 161
Note: See TracChangeset
for help on using the changeset viewer.