本文介绍了Bootstrap 3.0.3 form-group类它不带任何margin-bottom的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在这个新项目中使用Bootstrap 3.0.3,有一些奇怪的, form-group 类,它不采取任何 margin-bottom 。 是为了在标签控件。如果我将margin-bottom增加到一个大于15px的数字,它看起来像是在顶部加上边距。任何想法发生了什么?这是我的 。感谢。

I'm using Bootstrap 3.0.3 in this new project and there is something weird, the form-group class it is not taking any margin-bottom. The purpose of this class is to make vertical space between labels and controls. If I increase the margin-bottom to a number higher than 15px, it looks like the margin is been add up at the top. Any idea what's going on? This is my jsfiddle. Thanks.

推荐答案

如果我理解你想要正确完成的事情,你应该添加类 .form-horizo​​ntal 表单,如'Horizo​​ntal Form'部分所示:

If I understand what you're trying to accomplish correctly, you should add the class .form-horizontal to your form, as seen in the 'Horizontal Form' section here: http://getbootstrap.com/css/#forms-horizontal

这篇关于Bootstrap 3.0.3 form-group类它不带任何margin-bottom的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-02 16:35