• 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

codeigniter 4 running error first time with xampp

Laravel dosen't connect with Oracle

Open a popup box after receiving result from ajax

How do I upload a laravel project on cPanel shared hosting?

PHP to search within txt file and echo the whole line

phpMyAdmin ERROR: mysqli_real_connect(): (HY000/1045): Access denied for user 'pma'@'localhost' (using password: NO)

Laravel no logout option from menu after successfull login

Filter array by skipping every nth element from the end

Cut an arabic string

Edit product hook WooCommerce

Is it possible to re-use an array taken from PHP via JSON in a $.ajax function?

Warning: mysql_num_rows(): supplied argument is not a valid MySQL result resource [duplicate]

PHP DOTENV unable to load env vars

PHP's array_map including keys

Unable to guess the mime type as no guessers are available Laravel 5.2

About Contact Privacy policy Terms and conditions