1
2 <div class="alert alert-success alert-dismissible">
3 <a href="#" class="close" data-dismiss="alert" aria-label="close">×</a>
4 <strong>Success!</strong> Indicates a successful or positive action.
5
6 </div>
7
1Alerts in Bootstrap:
2--------------------------------
3Alert classes you can use to check
4.alert-primary
5.alert-secondary
6.alert-success
7.alert-danger
8.alert-warning
9.alert-info
10.alert-light
11.alert-dark
12
13Simple alert:
14-------------
15<div class="alert alert-primary" role="alert">
16 This is a primary alert—check it out!
17</div>
18
19Alert with close button and decriptive feature:
20------------------------------------------------
21<div class="alert alert-warning alert-dismissible fade show" role="alert">
22 <strong>Holy guacamole!</strong> You should check in on some of those fields below.
23 <button type="button" class="close" data-dismiss="alert" aria-label="Close">
24 <span aria-hidden="true">×</span>
25 </button>
26</div>
27
28Trigger via javascript:
29$(".alert").alert();
1
2 <div class="alert alert-success">
3 <strong>Success!</strong> You should <a href="#" class="alert-link">read this message</a>.
4</div>
5