CodeIgniter error logging set to 1:
/*
|--------------------------------------------------------------------------
| Error Logging Threshold
|--------------------------------------------------------------------------
|
| If you have enabled error logging, you can set an error threshold to
| determine what gets logged. Threshold options are:
| You can enable error logging by setting a threshold over zero. The
| threshold determines what gets logged. Threshold options are:
|
| 0 = Disables logging, Error logging TURNED OFF
| 1 = Error Messages (including PHP errors)
| 2 = Debug Messages
| 3 = Informational Messages
| 4 = All Messages
|
| For a live site you'll usually only enable Errors (1) to be logged otherwise
| your log files will fill up very fast.
|
*/
$config['log_threshold'] = 1;
Is it possible to suppress error messages for functions that are preceeded by a @?
For example, I have somewhere a need to detect if a string is serialized or not. I'm using code similar to the following:
public function is_serialized($data)
{
return (@unserialize($data) !== false);
}
Unfortunately, every time that $data is not serialized, it clogs up my error log even though I am using the @ operator.