14 lines
261 B
PHP
14 lines
261 B
PHP
<?php
|
|
$config = require_once __DIR__ . '/../config.php';
|
|
|
|
$db = new PDO(
|
|
$config->sql->dsn,
|
|
$config->sql->user,
|
|
$config->sql->password,
|
|
[
|
|
PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES utf8',
|
|
PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_OBJ
|
|
]
|
|
);
|
|
?>
|