title: set_exception_handler in codeigniter - how to use?
body: <p>I have a code similar to the following which is not working.</p>
  
  <pre><code>class Abc extends CI_Controller {
  
      static function exception_handler(Exception $ex)
      {       
          var_dump($ex);
          echo $ex-&gt;getMessage();
          exit;
      }
  
      function __construct()
      {
          parent::__construct();
          set_exception_handler('exception_handler');     
      }       
  
      function Index()
      {
  
          throw new Exception('hehe');
      }
  }   
  </code></pre>
  
  <p>I get </p>
  
  <blockquote>
    <p>A PHP Error was encountered</p>
    
    <p>Severity: Warning</p>
    
    <p>Message: set_exception_handler() expects the argument
    (exception_handler) to be a valid callback</p>
  </blockquote>
  
  <p>How to use set_exception_handler in codeigniter</p>