2014-07-15 44 views
1

我想有我引导复选框标签的复选框下,看起来像这样:最优雅的方式来定位标签,引导

bootstrap checkbox labels UNDER their checkboxes

我当前的代码是这样的:

<div class="well container-fluid text-center"> 
    <img src="dummy.png" class="img-circle img-responsive" /> 
    </br> 
    <lable for="check">Lable</lable> 
    </br> 
    </br> 
    <input type="checkbox" id="check"> 
</div> 

......但这看起来不太优雅。有没有更好的办法?

+0

在您的图片中,复选框位于标签下方。你所要求的和图片展示是不同的。 –

回答

1

我不能担保这是最优雅或最合适的解决方案,但它比在代码中使用换行符好得多。退房bootply

<div class="container"> 
<input type="checkbox"> 
<div class="row"> 
    <label>Label</label> 
</div> 

只需将您的复选框,然后把标签在一个新行。

+0

这已经看起来比换行更好! – LocalHorst

+0

@ user3351652不要忘记点击答案旁边的复选标记,如果这对你有帮助。另外,请查看http://getbootstrap.com/css/#grid获取更多格式帮助。 –