P
P
Padre2017-07-13 12:54:24
Yii
Padre, 2017-07-13 12:54:24

Is it possible to find out 404 errors in Yii2?

There is the simplest 404 error when accessing the page The
32ba6f87df5b446a82923039f6a694ac.png
question is, is it possible to somehow find out the details of why this address is 404?
1) Did the router work
2) Did it redirect the request to the required controller
3) Did the controller and the model
work 4) Or did everything work and there was no record in the
database how to find out in detail where the jamb is?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
M
Maxim Timofeev, 2017-07-13
@yii16

For this, there is a debug panel, which in yii2 is simply wonderful. Just turn it on and see all this info and more.
www.yiiframework.com/doc-2.0/yii-debug-module.html
in config:

'bootstrap' => ['log','debug'],
    'modules' => [
        'debug' => [
            'class' => 'yii\debug\Module',
            'allowedIPs' => ['тутВашIP'] //на локалке можно просто удалить эту строку
        ],
    ]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question