library x-phalcon-db
Phalcon DB
limingxinleo/x-phalcon-db
Phalcon DB
- Saturday, March 3, 2018
- by limingxinleo
- Repository
- 2 Watchers
- 3 Stars
- 2,403 Installations
- PHP
- 3 Dependents
- 0 Suggesters
- 0 Forks
- 0 Open issues
- 4 Versions
- 36 % Grown
X-Phalcon-DB
, (*1)
安装
composer require limingxinleo/x-phalcon-db
使用
<?php
use Phalcon\DI\FactoryDefault;
use Phalcon\Db\Adapter\Pdo\Mysql;
use PDO;
use Xin\DB;
// Your Method To Get DI;
$di = new FactoryDefault();
$di->setShared('db', function () {
return new Mysql(
[
'host' => '127.0.0.1',
'username' => 'root',
'password' => '910123',
'dbname' => 'phalcon',
'charset' => 'utf8',
'options' => [
PDO::ATTR_CASE => PDO::CASE_NATURAL,
PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
PDO::ATTR_ORACLE_NULLS => PDO::NULL_NATURAL,
PDO::ATTR_STRINGIFY_FETCHES => false,
PDO::ATTR_EMULATE_PREPARES => false,
],
]
);
});
$sql = "SELECT * FROM `test` WHERE `name` = ? LIMIT 1;";
$res = DB::query($sql, ['limx']);
dev-master
9999999-dev
Phalcon DB
Sources
Download
MIT
The Requires
-
ext-phalcon ^3.0
-
php >=5.6
The Development Requires
by
李铭昕
1.0.1
1.0.1.0
Phalcon DB
Sources
Download
MIT
The Requires
-
php >=5.6
-
ext-phalcon ^3.0
The Development Requires
by
李铭昕
0.0.1
0.0.1.0
Phalcon DB
Sources
Download
MIT
The Requires
-
php >=5.6.0
-
ext-phalcon ^3.0
The Development Requires
by
李铭昕
1.0.0
1.0.0.0
Phalcon DB
Sources
Download
MIT
The Requires
-
php >=5.6.0
-
ext-phalcon ^3.0
The Development Requires
by
李铭昕