From 65e82c1d23f5a2d2ec4a87b73441d3382eaee906 Mon Sep 17 00:00:00 2001 From: Robert Sesek Date: Mon, 27 May 2013 21:47:33 -0400 Subject: [PATCH] Set the PDO error mode to throw warnings. --- admin/htaccess | 5 +++++ includes/init.php | 2 ++ 2 files changed, 7 insertions(+) create mode 100644 admin/htaccess diff --git a/admin/htaccess b/admin/htaccess new file mode 100644 index 0000000..c877913 --- /dev/null +++ b/admin/htaccess @@ -0,0 +1,5 @@ +# TODO(port): Move this to BUGDAR_ROOT. +RewriteEngine on +RewriteCond %{REQUEST_FILENAME} !-f +RewriteCond %{REQUEST_FILENAME} !-d +RewriteRule (.*) index.php/$1 [QSA] \ No newline at end of file diff --git a/includes/init.php b/includes/init.php index 0bd6738..9627163 100755 --- a/includes/init.php +++ b/includes/init.php @@ -107,6 +107,8 @@ bugdar::$input = new \hoplite\http\Input(\hoplite\http\Input::TYPE_HTML); bugdar::$db = $db->dblink; +bugdar::$db->SetAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_WARNING); + // ################################################################### // send nocache header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); -- 2.43.5