You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
892 B
39 lines
892 B
11 years ago
|
Debug toolbar and debugger
|
||
|
==========================
|
||
|
|
||
11 years ago
|
Yii2 includes a handy toolbar to aid faster development and debugging as well as debugger. Toolbar displays information
|
||
|
about currently opened page while using debugger you can analyze data collected before.
|
||
|
|
||
|
Installing and configuring
|
||
|
--------------------------
|
||
|
|
||
11 years ago
|
Add these lines to your config file:
|
||
|
|
||
|
```
|
||
11 years ago
|
'preload' => ['debug'],
|
||
|
'modules' => [
|
||
|
'debug' => ['yii\debug\Module']
|
||
|
]
|
||
11 years ago
|
```
|
||
|
|
||
11 years ago
|
**Watch out: by default the debug module only works when browsing the website from the localhost. If you want to use it
|
||
11 years ago
|
on a remote (staging) server, add the parameter allowedIPs to the config to whitelist your IP, e.g. :**
|
||
|
|
||
|
```
|
||
|
'preload' => ['debug'],
|
||
|
'modules' => [
|
||
|
'debug' => [
|
||
|
'class'=>'yii\debug\Module',
|
||
|
'allowedIPs'=>['1.2.3.4', '127.0.0.1', '::1']
|
||
|
]
|
||
|
]
|
||
|
```
|
||
11 years ago
|
|
||
|
How to use it
|
||
|
-------------
|
||
|
|
||
11 years ago
|
|
||
11 years ago
|
Creating your own panels
|
||
|
------------------------
|
||
|
|