[eluser]AtlantixMedia[/eluser]
Hello,
can anyone tell me what's wrong with this?
MY_Exceptions in application/libraries
Code:
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class MY_Exceptions extends CI_Exceptions {
//==========================================================
function MY_Exceptions()
//==========================================================
{
parent::CI_Exceptions();
}
//==========================================================
function Log_To_Db($type = '', $severity = '', $message = '', $filepath = '', $line = '')
//==========================================================
{
$CI =& get_instance();
if ($CI->config->item('EnableErrorLogging') == 1)
{
$CI->load->model('Admin_Model');
$CI->Admin_Model->LogError_Q($type, $severity, $message, $filepath, $line);
}
}
}
I keep getting an error pointing to $CI =& get_instance();
Fatal error: Call to undefined function get_instance() in /home/content/../../../system/application/libraries/MY_Exceptions.php on line 86
thanks