Bootstrap popover不显示近按钮

时间:2015-07-17 14:36:46

标签: html css twitter-bootstrap

我正在尝试使用Bootstrap popover。它会弹出,但它不会出现在我的按钮附近,我无法找出原因。

HTML

#black{
   -webkit-filter: blur(10px);
    filter: url('/media/blur.svg#blur');
    filter: blur(10px);
}
#black p, #black h1{
padding-left: 10px;
padding-right: 10px;
padding-bottom: 10px
}

JQuery的

<div class="row">
    <div class="col-sm-12">
        <button type="button" class="btn btn-default" id="example1" 
                data-trigger="click" data-container="body" 
                data-toggle="popover" data-placement="top" 
                data-content="Vivamus sagittis lacus vel augue laoreet rutrum faucibus.">
          Popover on top
        </button>
    </div>            
</div>

<div class="row">
    <div class="col-sm-12">
        <h3>Client search</h3>
        <div class="input-group col-sm-5">
            <input placeholder="Search for ..." id="search_box" name="search_box"
                   title="Search for ..." class="form-control"  type="text" value="">
            <span class="input-group-addon">
                <i class="glyphicon glyphicon-search"></i>
            </span>
        </div>
    </div>
</div>

截图

Screenshot of issue

1 个答案:

答案 0 :(得分:1)

希望这有帮助

<button type="button" class="btn btn-default" data-container="body" data-toggle="popover" data-placement="top" data-content="Vivamus sagittis lacus vel augue laoreet rutrum faucibus.">
  Popover on top
</button>

您可以查看详细信息http://getbootstrap.com/javascript/#popovers