Merge pull request #5267 from miqrogroove/patch-2
Allow for Integer Literals in PDO Database Driver
This commit is contained in:
commit
4b0cf8d60f
|
@ -427,7 +427,12 @@ class dba {
|
|||
}
|
||||
|
||||
foreach ($args AS $param => $value) {
|
||||
$stmt->bindParam($param, $args[$param]);
|
||||
if (is_int($args[$param])) {
|
||||
$data_type = PDO::PARAM_INT;
|
||||
} else {
|
||||
$data_type = PDO::PARAM_STR;
|
||||
}
|
||||
$stmt->bindParam($param, $args[$param], $data_type);
|
||||
}
|
||||
|
||||
if (!$stmt->execute()) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user