Skip to content

Instantly share code, notes, and snippets.

@KINKCreative
Created November 23, 2016 19:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KINKCreative/ceb270fc1b281840edbd2fd1fa6222a5 to your computer and use it in GitHub Desktop.
Save KINKCreative/ceb270fc1b281840edbd2fd1fa6222a5 to your computer and use it in GitHub Desktop.
// log errors and warnings
SS_Log::add_writer(new SS_LogFileWriter('../silverstripe-errors-warnings.log'), SS_Log::WARN, '<=');
// or just errors
SS_Log::add_writer(new SS_LogFileWriter('../silverstripe-errors.log'), SS_Log::ERR);
// or notices (e.g. for Deprecation Notifications)
SS_Log::add_writer(new SS_LogFileWriter('../silverstripe-errors-notices.log'), SS_Log::NOTICE);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment