This is a small plugin that integrates Loggly logging with WordPress.
The configuration is currently all done via PHP constants that you can define in your wp-config.php file.
You MUST set a token to use the API. All other configuration is optional.
See https://{username}.loggly.com/tokens/ to get your token.
define( 'SIMPLE_LOGGER_FOR_LOGGLY_TOKEN', 'abcdef' );You can enable automatic integration with PHP error logs.
The default is off.
define( 'SIMPLE_LOGGER_FOR_LOGGLY_ERROR_HANDLER', true );You can customize the error log level to log to Loggly. It uses the same values as error_reporting().
The default level is to log all errors (E_ALL).
// Log only deprecation messages.
define( 'SIMPLE_LOGGER_FOR_LOGGLY_ERROR_LOG_LEVEL', E_DEPRECATED );You can customize the destination if needed or if you want to customize how it gets tagged. It must contain a "%s" for the token to be set in it dynamically.
The default is https://logs-01.loggly.com/inputs/%s/tag/http/
define( 'SIMPLE_LOGGER_FOR_LOGGLY_DESTINATION', 'https://logs-01.loggly.com/inputs/%s/tag/mytag/ ' );