Bootstrap Popover方法

!DOCTYPE htmlhtmlheadtitleTry v1.2 Bootstrap Online/titlelink href=/bootstrap/css/bootstrap.min.css rel=stylesheet

编程学习网为您整理以下代码实例,主要实现:Bootstrap Popover方法,希望可以帮到各位朋友。

<!DOCTYPE HTML>
<HTML>
<head>
   <Title>Try v1.2 bootstrap Online</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" style = "padding: 100px 50px 10px;" >
   <button type = "button" class = "btn btn-default popover-show" 
      Title = "Popover Title" data-container = "body" 
      data-toggle = "popover" data-placement = "left" 
      data-content = "Some content in Popover with show method">

      Popover on left
   </button>

   <button type = "button" class = "btn btn-primary popover-hIDe" 
      Title = "Popover Title" data-container = "body" 
      data-toggle = "popover" data-placement = "top" 
      data-content = "Some content in Popover-hIDe method">

      Popover on top
   </button>

   <button type = "button" class = "btn btn-success popover-destroy" 
      Title = "Popover Title" data-container = "body" 
      data-toggle = "popover" data-placement = "bottom" 
      data-content = "Some content in Popover-destroy method">

      Popover on bottom
   </button>

   <button type = "button" class = "btn btn-warning popover-toggle" 
      Title = "Popover Title" data-container = "body" 
      data-toggle = "popover" data-placement = "top" 
      data-content = "Some content in Popover-toggle method">

      Popover on right
   </button>

   <br><br><br><br><br><br>

   <p class = "popover-options">
      <a href = "#" type = "button" class = "btn btn-warning" 
         Title = "<h2>Title</h2>" data-container = "body" 
         data-toggle = "popover" data-content = "
         <h4>Some content in Popover-options method</h4>">

         Popover
      </a>
   </p>

   <script>
      $(function () { $('.popover-show').popover('show');});
      $(function () { $('.popover-hIDe').popover('hIDe');});
      $(function () { $('.popover-destroy').popover('destroy');});
      $(function () { $('.popover-toggle').popover('toggle');});
      $(function () { $(".popover-options a").popover({HTML : true });});
   </script>
</div>

</body>
</HTML>
本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐