在 Bootstrap 縮覽圖中新增 HTML 標題


使用 Bootstrap,你可以輕鬆地為縮覽圖新增標題。

你可以嘗試執行以下程式碼以新增 HTML 標題 −

示例

即時演示

<!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 = "row">
         <div class = "col-sm-6 col-md-3">
            <div class = "thumbnail">
               <img src = "/bootstrap/images/kittens.jpg" alt = "Kittens">
            </div>
            <div class = "caption">
               <h3>Thumbnail Heading</h3>
            </div>
         </div>
      </div>
   </body>
</html>

更新於:2020 年 6 月 12 日

242 次瀏覽

開啟你的 職業生涯

透過完成課程獲得認證

入門
廣告
© . All rights reserved.