I found a general ThinkPHP database configuration file, which is used to connect to the database. It is relatively simple and suitable for corporate sites. , there are very few parameters to configure, so you can use it directly when building small websites such as enterprise type, as shown below.
if(!defined('THINK_PATH')) exit();
return $array = array (
'DB_TYPE' => 'mysql',
' DB_HOST' => 'localhost',
'DB_NAME' => 'hbhongtaizhuangshi',
'DB_USER' => 'root',
'DB_PWD' => 'meimimaa',
'DB_PORT' => 3306,
'DB_PREFIX' => 'zx_',
'DB_BACKUP' => '/Data/backup',
'URL_MODEL' => 0,
);
?>
Placing it in our ThinkPHP config.php file is ok.