javascript - Why is the dismissible alert not being dismissed? -


note: let me start saying i'm aware of question solution incomplete , don't yet have not enough reputation on stackoverflow comment on it. so, left option of creating duplicate question.

i'm trying use angularjs , bootstrap (ui-bootstrap) show dismissible alert. however, after including ui-bootstrap-tpls-*.js file (solution suggested on original question) doesn't seem work. although work jquery.

please check plunker

i found way have dismissible alert without adding logic controller. don't need bootstrap-*-js. have alert close button uses ng-click on $scope variable hide parent div on ng-show. (the controller sets variable whether alert should shown or not.)

<div class="alert alert-warning" ng-show="show_alert">   <button type="button" class="close" ng-click="show_alert=false">&times;</button>   <strong>warning!</strong> best check yo self, you're not looking good. </div> 

the css classes alert alert-warning , close styled bootstrap.

check out plunker above solution.


Comments

Popular posts from this blog

c++ - OpenCV Error: Assertion failed <scn == 3 ::scn == 4> in unknown function, -

php - render data via PDO::FETCH_FUNC vs loop -

The canvas has been tainted by cross-origin data in chrome only -