创建配置文件
pdo_config.php
创建配置文件
pdo_config.php
<?php
$db_Type = "mysql";//数据库类型
$host = "localhost";//主机名
$dbName = "test";//数据库名
$userName = "root";//用户名
$password = "root";//密码
$dsn = "{$db_Type}:host={$host};dbname={$dbName}";
?>创建配置文件
pdo_config.ph