wc_logs_settings_form_fields
Action fires after the built-in logging settings controls have been rendered.
This is intended as a way to allow other logging settings controls to be added by extensions.
Usage
add_action( 'wc_logs_settings_form_fields', 'wp_kama_wc_logs_settings_form_fields_action' ); /** * Function for `wc_logs_settings_form_fields` action-hook. * * @param bool $enabled True if logging is currently enabled. * * @return void */ function wp_kama_wc_logs_settings_form_fields_action( $enabled ){ // action... }
- $enabled(true|false)
- True if logging is currently enabled.
Changelog
Since 8.6.0 | Introduced. |
Where the hook is called
wc_logs_settings_form_fields
woocommerce/src/Internal/Admin/Logging/Settings.php 434
do_action( 'wc_logs_settings_form_fields', $this->logging_is_enabled() );