Download the PHP package kodansha/wack-log without Composer
On this page you can find all versions of the php package kodansha/wack-log. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download kodansha/wack-log
More information about kodansha/wack-log
Files in kodansha/wack-log
Package wack-log
Short Description Simple logger plugin to output logs to stdout.
License GPL-3.0-or-later
Homepage https://github.com/kodansha/wack-log
Informations about the package wack-log
WACK Log
WACK Log is a simple WordPress plugin to output logs to the stdout.
It is created as a thin Monolog wrapper with the intention of being used with the WACK Stack, but it can also be used with other WordPress installations, especially convenient for those that are containerized.
Installation
- Requires PHP 8.1 or later
- Requires WordPress 6.0 or later
- Requires Composer
Using Composer
[!NOTE] This plugin is not available on the WordPress.org plugin repository. For the moment, the only way to install it is to use Composer.
Usage
WACK Log exposes a global function logger()
that can be used as below:
In addition, it also provides a shorthand usage that is convenient for debugging:
Configuration
There are two methods for customizing the behavior of WACK Log:
- Setting through the
WACK_LOG_SETTINGS
constant - Setting via the settings screen in the WordPress admin menu
Setting via WACK_LOG_SETTINGS
Define WACK_LOG_SETTINGS
in functions.php or similar:
Setting via WordPress admin menu
Go to the settings screen of WACK Log in the WordPress admin menu and follow the instructions on the screen.
[!NOTE] If settings exist both in
WACK_LOG_SETTINGS
and the admin menu settings at the same time, the settings defined in the constant are prioritized as a general rule.