HTML CSS examples for Bootstrap Class List:alert-success
alert-success
<!DOCTYPE html> <html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.2.1/jquery.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.12.6/umd/popper.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/js/bootstrap.min.js"></script> </head><!-- w ww .j av a 2s . c o m--> <body> <div class="container"> <h2>Alerts</h2> <p>Alerts are created with the .alert class, followed by a contextual color classes:</p> <div class="alert alert-success"> <strong>Success!</strong> This alert box could indicate a successful or positive action. </div> <div class="alert alert-info"> <strong>Info!</strong> This alert box could indicate a neutral informative change or action. </div> <div class="alert alert-warning"> <strong>Warning!</strong> This alert box could indicate a warning that might need attention. </div> <div class="alert alert-danger"> <strong>Danger!</strong> This alert box could indicate a dangerous or potentially negative action. </div> <div class="alert alert-primary"> ? <strong>Primary!</strong> Indicates an important action. </div> <div class="alert alert-secondary"> ? <strong>Secondary!</strong> Indicates a slightly less important action. </div> <div class="alert alert-dark"> ? <strong>Dark!</strong> Dark grey alert. </div> <div class="alert alert-light"> ? <strong>Light!</strong> Light grey alert. </div> </div> </body> </html>