bootstrap modal is not working in login page


Its really annoying that bootstrap modal is not working in login page.

I have copied modal code from bootstrap site and have pasted it on login page. when i am trying to open modal by clicking on button its getting displayed for moment and some properties making display none.

I have tried same code on simple html file and its working fine but when i am trying with yii its not working.

Any suggestion would be appreciated…

P.S. :- i am trying it in fresh yii app. (so there is no involvement of my code to making display none to modal).


Got solution :). Posting answer so it might help someone…

i forgot to include ‘yii\bootstrap\BootstrapPluginAsset’ in assest class.

AppAsset class will look like following after including :

public $depends = [





we should have to include bootstrap.js manually. by default only bootstrap.css will get included.

plz share how to show login model window in place of login page.