我试图使用bootstarp class =“form-inline”在一行中对齐几个控件,但它似乎不能正常工作。任何人都可以建议我做错了什么.. !!
目前我的结果是两行。我希望它们显示在一行
我使用的代码如下
<div class="form-inline">
<i class="icon-list-alt"></i>
<label class="control-label">
Please enter TB Id or TBR Id</label>
<div class="form-search">
<div class="input-append">
<input id="inputValue" type="text" class="span2 search-query" />
<div class="btn-group">
<button class="btn dropdown-toggle" data-toggle="dropdown">
<span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu">
<li><a id="POA" tabindex="-1" href="#">1</a></li>
<li><a id="MOD" tabindex="-1" href="#">2</a></li>
<li><a id="LC" tabindex="-1" href="#">3</a></li>
</ul>
</div>
</div>
</div>
</div>
答案 0 :(得分:1)
检查此代码,希望它有所帮助:
<div class="form-inline">
<i class="icon-list-alt"></i>
<label class="control-label">
Please enter TB Id or TBR Id</label>
<span class="form-search">
<div class="input-append">
<input id="inputValue" type="text" class="span2 search-query" />
<div class="btn-group">
<button class="btn dropdown-toggle" data-toggle="dropdown">
<span class="caret"></span>
</button>
<ul class="dropdown-menu" role="menu" aria-labelledby="dropdownMenu">
<li><a id="POA" tabindex="-1" href="#">1</a></li>
<li><a id="MOD" tabindex="-1" href="#">2</a></li>
<li><a id="LC" tabindex="-1" href="#">3</a></li>
</ul>
</div>
</div>
</span>
</div>