要CI框架的错误提示,除了需要在index.php设置define('ENVIRONMENT', 'production');还要在database.php中$db['default']['db_debug'] = FALSE;不然sql错误会暴露。