mirror of
https://github.com/e107inc/e107.git
synced 2025-08-01 12:20:44 +02:00
#605 - Fix for PDO insert entering empty data.
This commit is contained in:
@@ -415,6 +415,12 @@ class e_db_mysql
|
||||
|
||||
if($this->pdo)
|
||||
{
|
||||
// print_a($query);
|
||||
// $prep = $this->mySQLaccess->prepare($query);
|
||||
// print_a($query);
|
||||
// print_a($prep);
|
||||
// echo "<hr>";
|
||||
// $sQryRes = $prep->execute($query);
|
||||
$sQryRes = $this->mySQLaccess->query($query);
|
||||
}
|
||||
else
|
||||
@@ -746,6 +752,8 @@ class e_db_mysql
|
||||
$tmp[] = $this->_getFieldValue($fk, $fv, $fieldTypes);
|
||||
}
|
||||
$valList= implode(', ', $tmp);
|
||||
|
||||
|
||||
unset($tmp);
|
||||
|
||||
if($REPLACE === FALSE)
|
||||
@@ -1710,6 +1718,12 @@ class e_db_mysql
|
||||
*/
|
||||
function escape($data, $strip = true)
|
||||
{
|
||||
|
||||
if($this->pdo)
|
||||
{
|
||||
return $data;
|
||||
}
|
||||
|
||||
if ($strip)
|
||||
{
|
||||
$data = strip_if_magic($data);
|
||||
@@ -1721,6 +1735,8 @@ class e_db_mysql
|
||||
$this->mySQLaccess = $db_ConnectionID;
|
||||
}
|
||||
|
||||
|
||||
|
||||
return mysql_real_escape_string($data,$this->mySQLaccess);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user