Yii2: Debug Toolbar throws 'Bad Request (#400): Missing required parameters: tag'

Created on 12 May 2016  Â·  4Comments  Â·  Source: yiisoft/yii2

I have debug toolbar turned on, but in source code I see:

<div id="yii-debug-toolbar" data-url="/debug/default/toolbar?tag=5734a917576ac" style="display:none" class="yii-debug-toolbar-bottom">Bad Request (#400): Missing required parameters: tag</div>

Config:

'log'          => [
            'traceLevel' => YII_DEBUG ? 3 : 0,
            'targets'    => [
                [
                    'class'  => 'yii\log\FileTarget',
                    'levels' => [ 'error', 'warning' ],
                ],
            ],
        ],

Htaccess:

RewriteEngine on

# if a directory or a file exists, use it directly
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

# otherwise forward it to index.php
RewriteRule ^.*$ /index.php? [L]

Versions:

Yii 2.0.8
PHP 5.4.13
‪CentOS 6.5 (Final)‬

question

Most helpful comment

Try to change

RewriteRule ^.*$ /index.php? [L]

to

RewriteRule . index.php

All 4 comments

_This is an automated comment, triggered by adding the label question._

Please note, that the GitHub Issue Tracker is for bug reports and feature requests only.

We are happy to help you on the support forum, on IRC (#yii on freenode), or Gitter.

Please use one of the above mentioned resources to discuss the problem.
If the result of the discussion turns out that there really is a bug in the framework, feel free to
come back and provide information on how to reproduce the issue. This issue will be closed for now.

I think this problem is related to your env rather then to Yii core.

Try to change

RewriteRule ^.*$ /index.php? [L]

to

RewriteRule . index.php

For others who run into the issue @SilverFire's solution solved the issue by changing the rewriterule in .httaccess

Was this page helpful?
0 / 5 - 0 ratings