【问题标题】:Why is bootstrap horizontal form failing?为什么引导水平形式失败?
【发布时间】:2015-06-25 11:18:02
【问题描述】:

如果需要更大的图片:http://i.imgur.com/mhjKhQ9.png?1

   <div class="container">
        <div class = "row">
            <div class = "col-md-12">
                <form class="form-horizontal">
                    <div class="input-group">
                        <label for="officeSelection">Office</label>
                        <select data-ng-model="userSelections.office"
                                data-ng-options="o.name for o in officesInOrg"
                                name = "officeSelection"
                                id = "officeSelection"
                                class="form-control"
                                placeholder="Office"
                                ng-change = "officeSelected()">
                        </select>
                    </div>
                </form>
            </div>
        </div>
    </div>
  1. 为什么不维护引导程序horizontal form format
  2. 如何调整大小(输入字段宽度)。上面链接中的示例不起作用(包含更多 class="col-md-x" div),但我认为引导程序可能在这里总体上失败,我不知道为什么。

【问题讨论】:

    标签: twitter-bootstrap


    【解决方案1】:

    显然“输入组”与“表单组”确实很重要。只是出于好奇- class="form-control" 也是必不可少的。我猜输入组仅适用于appending inputs

     <div class="form-group">
                    <label for="officeSelection" class="col-md-offset-3 col-md-2 control-label">Office</label>
                    <div class="col-md-4">
                        <select data-ng-model="userSelections.officeId"
                                data-ng-options="o.id as o.name for o in selectionOptions.officesInOrg"
                                name = "officeSelection"
                                id = "officeSelection"
                                class="form-control"
                                placeholder="Office"
                                ng-change = "officeSelected()">
                        </select>
                    </div>
    </div>
    

    【讨论】:

      猜你喜欢
      • 2018-03-04
      • 2021-04-06
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-10-10
      • 1970-01-01
      • 2013-04-06
      • 2019-01-02
      相关资源
      最近更新 更多