在 Bootstrap 中创建有边框的列表组
要使用 Bootstrap 中的 .list-group 类来创建一个有边框的列表组。
你可以试着运行以下代码来实现 .list-group 类:
示例
<!DOCTYPE html> <html> <head> <title>Bootstrap Example</title> <link href = "/bootstrap/css/bootstrap.min.css" rel = "stylesheet"> <script src = "/scripts/jquery.min.js"></script> <script src = "/bootstrap/js/bootstrap.min.js"></script> </head> <body> <div class = "container"> <h3>Countries</h3> <ul class = "list-group"> <li class = "list-group-item">US</li> <li class = "list-group-item">India</li> <li class = "list-group-item">Netherlands</li> <li class = "list-group-item">Germany</li> </ul> </div> </body> </html>
广告