dev-master
9999999-devJazz framework DbConnect component
MIT
The Development Requires
by Sergey Malahov
1.0.0
1.0.0.0Jazz framework DbConnect component
MIT
The Development Requires
by Sergey Malahov
Wallogit.com
2017 © Pedro Peláez
Jazz framework DbConnect component
Most popular framework DbConnect component, (*1)
This is a factory PDO based class. Can store multiple instances of connections. Simple and useful., (*2)
The preferred way to install this Jazz framework DbConnect component is through composer., (*3)
Either run, (*4)
php composer.phar require "qwant50/dbconnect"
or add, (*5)
"qwant50/dbconnect": "~1.*.*"
to the require section of your composer.json., (*6)
$db = DbConnect::getInstance(['connectionName' => 'db1',
'host' => '127.0.0.1',
'dbname' => 'test',
'username' => 'webuser',
'password' => 'xxxxxxxx',]);
$db = DbConnect::getInstance(['connectionName' => 'db1',
'host' => '127.0.0.1',
'dbname' => 'test',
'username' => 'webuser',
'password' => 'xxxxxxxx',])->getConnection();
$db = DbConnect::getInstance(['connectionName' => 'db1',
'host' => '127.0.0.1',
'dbname' => 'test',
'username' => 'webuser',
'password' => 'xxxxxxxx',])->getConnection();
$stmt = $db->prepare("SELECT * FROM table_name WHERE login = :login");
$stmt->bindParam(':login', $login);
$stmt->execute();
Jazz framework DbConnect component
MIT
Jazz framework DbConnect component
MIT