Bootstrap collapse樣式
翻譯結果:
collapse
英[kəˈlæps] 美[kəˈlæps]
##v.崩潰;倒塌;折疊;(尤指工作勞累後)坐下#vt.使倒塌;使崩塌;使瓦解n.垮台;(身體的)衰弱Bootstrap collapse樣式語法
作用:隱藏內容。
Bootstrap collapse樣式範例
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>php中文网(php.cn)</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://cdn.bootcss.com/bootstrap/3.3.7/css/bootstrap.min.css"> <script src="https://cdn.bootcss.com/jquery/2.1.1/jquery.min.js"></script> <script src="https://cdn.bootcss.com/bootstrap/3.3.7/js/bootstrap.min.js"></script> </head> <body> <div class="container"> <h2>Simple Collapsible</h2> <button type="button" class="btn btn-info" data-toggle="collapse" data-target="#demo">简单的折叠</button> <div id="demo" class="collapse"> Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. </div> </div> </body> </html>
#點擊 "執行實例" 按鈕查看線上實例