【问题标题】:Bootstrap - two/three inputs in one lineBootstrap - 一行中的两个/三个输入
【发布时间】:2015-04-20 21:18:19
【问题描述】:

我想用 bootstrap 写两个或三个输入: 它应该看起来像:

label
input input input

label
input(30%) input(40%) input (30%)

这是我的代码:

<form>
  <div class="form-group">
    <label><strong>test:</strong></label>
    <input class="form-control" style="width: 30%"/>
    <input class="form-control" style="width: 40%"/>
    <input class="form-control" style="width: 30%"/>
  </div>
</form>

【问题讨论】:

  • 似乎是什么问题?你有问题吗?
  • 我写过我正在寻找帮助来组织这个表格,就像我写的一样。
  • 不要误会我的意思,但我仍然不确定您的问题是什么。我想很清楚你想要什么。目前还不清楚您尝试了什么以及为什么没有奏效。

标签: javascript html css asp.net-mvc twitter-bootstrap


【解决方案1】:

只需使用行,它们几乎可以在任何地方插入。

<link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css" rel="stylesheet"/>
<div class="form-group">
  <label>Name</label>
    <div class="row">
    <div class="col-xs-4"><input type="text" class="form-control"></div>
    <div class="col-xs-4"><input type="text" class="form-control"></div>
    <div class="col-xs-4"><input type="text" class="form-control"></div>
  </div>
</div>

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2021-11-12
    • 2016-02-20
    • 2023-03-02
    • 2018-06-06
    • 1970-01-01
    • 1970-01-01
    • 2016-05-20
    相关资源
    最近更新 更多