How to prevent CodeIgniter from showing errors and warnings

Posted by : Leo T Abraham on 18 July, 2013

Prevent the site from showing errors, warnings and notice in the live environment are crucial for entire site security. Hackers can easily identify the table and table fields if some of these errors are shown in the live environment. In order to prevent this from showing CodeIgniter has got an easy method. Following are the steps:

In the root folder, open the file index.php and change
define('ENVIRONMENT', 'development'); to define('ENVIRONMENT', 'production');