Hi guys,CSS files for the AdminLTE user-interface won’t be rendered if I will set
'enablePrettyUrl' => true
There are no problems, if enablePrettyUrl will be set to false.Unfortunately, I need my rules. So, what kind of rule will be needed to fix this…
Here is a cut of my config file
'components' => [
'assetManager' => [
'bundles' => [
'dmstr\web\AdminLteAsset' => [
'skin' => 'skin-blue',
],
],
],
'urlManager' => [
'class' => 'yii\web\UrlManager',
'enablePrettyUrl' => true,//won't render adminlte-css
'showScriptName' => true,
'enableStrictParsing' => true,
'rules' => [
'/' => 'site/login',
'home' => 'site/index',
'reset' => 'site/request-password-reset',
'about' => 'site/about',
'contact' => 'site/contact',
'logout' => 'site/logout',
'signup' => 'site/signup',
'signup' => 'site/signup',
'gii' => '/gii',
'debugger' => '/debug',
'<controller:\w+>/<id:\d+>' => '<controller>/view',
'<controller:\w+>/<id:\d+>' => '<controller>/save-as-new',
'<controller:\w+>/<action:\w+>/<id:\d+>' => '<controller>/<action>',
'<action:(contact|captcha)>' => 'site/<action>',
],
],
'view' => [
'theme' => [
'pathMap' => [
'@app/views' => '@vendor/dmstr/yii2-adminlte-asset/example-views/yiisoft/yii2-app'
],
],
],
],
];
P.S.: I just have noticed, that everything works fine, if I will change url startup like this
'/' => 'site/index',
'login' => 'site/login'
.Of course,this is no solution of my problem, but it’s amazing…