How to turn off mysql errors from being displayed to screen in CodeIgniter
Found the answer:
In config/database.php:
// ['db_debug'] TRUE/FALSE - Whether database errors should be displayed.
so:
$db['default']['db_debug'] = FALSE;
... should disable.
In addition to Ian's answer, to temporarily disable the error messages:
$db_debug = $this->db->db_debug;$this->db->db_debug = false;// Do your sketchy stuff here$this->db->db_debug = $db_debug;
You don't want to changeerror_reporting to 0, because that willalso suppress errors from beinglogged.
instead you should change display_errors to 0
This doesn't explain why you are getting errors displayed though, assuming error_reporting is actually 0. Maybe the framework handles these errors