pdo 的连接代码如下:
function db_connect()
{
$this->options['PDO::ATTR_ERRMODE'] = PDO::ERRMODE_SILENT;
return new PDO($this->hostname, $this->username, $this->password, $this->options);
}
PDO 曾经的连接方式是这样的吗? new PDO 第一个参数不是 dsn??
pdo 的连接代码如下:
function db_connect()
{
$this->options['PDO::ATTR_ERRMODE'] = PDO::ERRMODE_SILENT;
return new PDO($this->hostname, $this->username, $this->password, $this->options);
}
PDO 曾经的连接方式是这样的吗? new PDO 第一个参数不是 dsn??