Yii 2.0: Tutorial about How to Integrate Yii2 with fantastic theme AdminLTE


Yii2 comes with a charming twitter bootstrap version 3. But if it is less, then you can integrate with web templates that you like. One example is wonderfull template "adminLTE"

You can use ready-skeleton on GitHub also.

With Yii2 we can do it easily, the following steps

  • Add your composer.json
"bower-asset/admin-lte": "*"
  • Change your AppAsset.php and check to referring it in your views/layouts/main.php
class AppAsset extends AssetBundle
    public $sourcePath = '@bower/';
    public $css = ['admin-lte/css/AdminLTE.css'];
    public $js = ['admin-lte/js/AdminLTE/app.js'];
    public $depends = [
  • Change your views adhering to html markup vendor/bower/admin-lte/pages

Total 9 comments

#20044 report it
Federico Benedetti at 2017/03/12 07:41pm
Update AssetBundle path

probably this page must be updated. I try a fresh Admin-lte installation and the right AssetBundle is:

class AppAsset extends AssetBundle
    public $sourcePath = '@bower/';
    public $css = ['admin-lte/dist/css/AdminLTE.css'];
    public $js = ['admin-lte/dist/js/app.js'];
    public $depends = [
#19821 report it
Ventoh at 2016/04/01 01:42pm
How extends the css?

Please, how can i customize the AdminLTE.css?

#19205 report it
antonior14 at 2015/04/15 11:34am
problems installing theme

hi! I'm trying to install adminlte theme following guide but it can run... :(

#18602 report it
YiiJeka at 2014/11/28 03:28am
Issue with yii2 advanced backend theme

@Muhammad Shahzad Tutorial updated. It should solve your problem now.

#18540 report it
Amjad Khan at 2014/11/12 12:15pm
checkbox problem in Gridview of AdminLTE

using this theme if i use checkboxes in gridview then clicking on header checkbox the checkboxs for the remaining records cannot be selected.

#18042 report it
Muhammad Shahzad at 2014/09/01 08:21am
Issue with yii2 advanced backend theme

Hi, I have installed yii2 advanced,and I want to change backend theme. I followed your instruction,but nothing changed, Is there any file where I need to tell yii2 that use adminlte theme?

#17989 report it
m3hr@n at 2014/08/23 07:38am
How about Yii 1

It is fantastic!! could I integrate Yii 1.1.X with fantastic theme AdminLTE? If yes, then how?

#17848 report it
VictorG at 2014/07/29 07:53pm
Demo layout

Very nice!

It would be great if you could write a short article about how you built the layout of the demo.

Thanks for your work!

#17760 report it
ThePr0f3550r at 2014/07/20 07:28pm


username: admin password: admin

Leave a comment

Please to leave your comment.

Write new article