WP_CLI::log
Display informational message without prefix.
Message is written to STDOUT, or discarded when --quiet flag is supplied.
# `wp cli update` lets user know of each step in the update process. WP_CLI::log( sprintf( 'Downloading from %s...', $download_url ) );
Метод класса: WP_CLI{}
Хуков нет.
Возвращает
null. Ничего (null).
Использование
$result = WP_CLI::log( $message );
- $message(строка) (обязательный)
- Message to write to STDOUT.
Код WP_CLI::log() WP CLI::log WP-CLI 2.13.0-alpha
public static function log( $message ) {
if ( null === self::$logger ) {
return;
}
self::$logger->info( $message );
}