Skip to content

Instantly share code, notes, and snippets.

@aufa
Last active September 13, 2016 19:51
Show Gist options
  • Save aufa/e8cbcb48f7e70a263a3ccd5809050b8d to your computer and use it in GitHub Desktop.
Save aufa/e8cbcb48f7e70a263a3ccd5809050b8d to your computer and use it in GitHub Desktop.
<?php
$database = \MyNameSpace\ExamDB::create(
'mysql',
[
'dbuser' => 'root',
'dbpass' => 'password',
'dbname' => 'test',
'host' => 'localhost'
],
true // debug true throwed if error
);
$tables = $database->quoteIdentifier(['my.table', 'my.table2', 'my.table3']);
/*
array(
0 => `my`.`table`,
1 => `my`.`table2`,
2 => `my`.`table3`
)
*/
print_r($tables);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment