From: Nicolas Boisselier Date: Thu, 14 Dec 2017 21:55:46 +0000 (+0000) Subject: lib/php/db/table.php X-Git-Url: https://git.nbdom.net/?a=commitdiff_plain;h=1c44522e416beb17784b28b2dbb2d98ecf2808fb;p=nb.git lib/php/db/table.php --- diff --git a/lib/php/db/table.php b/lib/php/db/table.php index 6f067d9a..a53903be 100644 --- a/lib/php/db/table.php +++ b/lib/php/db/table.php @@ -1711,7 +1711,8 @@ Class Table extends nb { $keys_values = []; $fields = []; $fields_values = []; - $bindParam = false; # NB 12.05.17: Not working ???? +# NB 14.12.17 $bindParam = false; # NB 12.05.17: Not working ???? + $bindParam = true; # NB 12.05.17: Not working ???? foreach ($this->fields() as $name => $field) { @@ -1774,7 +1775,7 @@ Class Table extends nb { $info = [ 'sql' => $sql ] + $info; if ($bindParam and !($query = $this->db()->conn->prepare($sql))) { - err('PDO::errorInfo(): ' .join(' ', $this->db()->conn->errorInfo()) .NB_EOL); + $this->err('PDO::errorInfo(): ' .join(' ', $this->db()->conn->errorInfo()) .NB_EOL); return false; } diff --git a/www/dbq/dbq.php b/www/dbq/dbq.php index 462c750c..004fcdca 100644 --- a/www/dbq/dbq.php +++ b/www/dbq/dbq.php @@ -388,7 +388,8 @@ class DbQ extends nb { } $this->table->html_edit($values, - $this->table->base . '/' . ($add ? 'insert' : 'update' . '/' . urlencode($this->params['args'])) . '/' +# NB 14.12.17 $this->table->base . '/' . ($add ? 'insert' : 'update' . '/' . urlencode($this->params['args'])) . '/' + $this->table->base . '/' . ($add ? 'insert' : 'update') . '/' ,$add); }