• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

Yii2: How do I debug console commands?

phpdebuggingconsoleyii2command-line-interface


PHP Snippet 1:

'log' => [
'targets' => [[
    ...
], [
    'class' => 'yii\log\FileTarget',
    'logFile' => '@runtime/logs/profile.log',
    'logVars' => [],
    'levels' => ['profile'],
    'categories' => ['yii\db\Command::query'],
    'prefix' => function($message) {
        return '';
    }
]]

PHP Snippet 2:

[
    'class' => 'yii\log\FileTarget',
    'levels' => ['info', 'error', 'warning'],
],

Related Snippets

Download & Save Zoom Recording in directory by PHP

How to remove from a multidimensional array all duplicate elements including the original?

Is there a way to use the same parameter into multiple place in the same query with Eloquent? [duplicate]

Woocommerce Checkout - Add conditional field required if one field is filled

run a query using EXECUTE BLOCK to prepair a column for an unique-Index

How to use $this->session->set_userdata in codeigniter

how do i retrieve and display the alt text of an image in wordpress?

Additional price based on cart item count in WooCommerce

Access denied for user 'homestead'@'localhost' (using password: YES)

Unable to Edit config.inc.php

How to fix " Uncaught TypeError: Argument 1 passed to JpGraphException::defaultHandler() " problem in php 7.1.3 and jpgraph 4.2.6?

Fetch files from next cloud storage and display in Laravel website

How to break out of a foreach once a condition is met?

PHP contact form configuration [duplicate]

PHP's array_map including keys

About Contact Privacy policy Terms and conditions