classes/Utilities/Logging/DatabaseLogger.php
public function log($channel, $level, $message, $context = '') {
        if (!$this->enabled) {
            return;
        }

        $message = ltrim($message);

        global $wpdb;

        $query = $wpdb->prepare("insert into {$this->table} (date, channel, level, message, context) values (%s, %s, %s, %s, %s)", current_time('mysql', true), $channel, $level, $message, $context);
        $wpdb->query($query);
    }
public function log($channel, $level, $message, $context = '') {
        if (!$this->enabled) {
            return;
        }

        $message = ltrim($message);

        global $wpdb;

        $query = $wpdb->prepare("insert into {$this->table} (date, channel, level, message, context) values (%s, %s, %s, %s, %s)", current_time('mysql', true), $channel, $level, $message, $context);
        $wpdb->query($query);
    }
public function log ( $ channel , $ level , $ message , $ context = '' ) { if ( ! $ this -> enabled ) { return ; } $ message = ltrim ( $ message ) ; global $ wpdb ; $ query = $ wpdb -> prepare ( "insert into {$this->table} (date, channel, level, message, context) values (%s, %s, %s, %s, %s)" , current_time ( 'mysql' , true ) , $ channel , $ level , $ message , $ context ) ; $ wpdb -> query ( $ query ) ; }
Logs to the database

@param $channel
@param $level
@param $message
@param $context
Logs to the database