CodeIgniter Tutorial News section |
In CI, the error reporting level depends on the ENVIRONMENT setting in index.php.
There is a line with this code: PHP Code: define('ENVIRONMENT', isset($_SERVER['CI_ENV']) ? $_SERVER['CI_ENV'] : 'development'); If you're not sure about that, you can simply define the ENVIRONMENT constant like this: PHP Code: define('ENVIRONMENT','development'); PHP Code: define('ENVIRONMENT','production'); The first one is using the 'development' environment, the other one 'production'. When I upload my website, I make sure that on the hosted server, my index_production.php is renamed to index.php. A bit lower in index.php, you will see a "switch (ENVIRONMENT) { }" structure. With that, the correct error reporting level is set, depending on the value of the ENVIRONMENT constant. The different levels are explained here: http://php.net/manual/en/function.error-reporting.php |
Welcome Guest, Not a member yet? Register Sign In |