css - 使用 Bootstrap 的类在表内调整输入文本的大小

标签 css html twitter-bootstrap html-table

我在下面的代码中尝试使用 Bootstrap 的类调整文本输入元素的大小。但是,我无法缩小尺寸。我希望它在桌面上更小,而不是占用大量空间。

<div class="container White_BG">
<div class="row" style="margin-left:0;margin-right:0;">
<div class="col-xs-12 col-sm-12 col-md-12 col-lg-12">

<h1>Quickly place your order with this form.</h1>
<h2>Please enter the item numbers that you wish to order; once you add to the cart, then you will be able to change the quantity of those items ordered.</h2>

<div class="table-responsive">
    <form method="post" name="QuickOrderMulti">
        <table class="table table-bordered table-condensed table-hover">
            <tr>
                <th>Item #</th>
                <th>Quantity</th>
                <th>Description</th>
                <th>Price</th>
                <th>Subtotal</th>
            </tr>
            <tr>
                <td>
                    <div class="col-lg-2">
                        <input type="text">
                    </div>
                </td>
                <td>
                    <input type="text">
                </td>
                <td>

                </td>
                <td>

                </td>
                <td>

                </td>
            </tr>
        </table>
    </form>
</div>

</div>
</div>
</div>

违规行是:

<td>
    <div class="col-lg-2">
        <input type="text">
    </div>
</td>

我尝试使用 col-lg-2 让它只占用 2 个网格列,所以它可能会更小。但没有这样的运气。

最佳答案

与其将它包围在一个 div 中,不如尝试使用所选类进行输入。

例如

<input class="col-lg-2" type="text">

关于css - 使用 Bootstrap 的类在表内调整输入文本的大小,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22789584/

相关文章:

html - 在 Internet Explorer 8 中隐藏输入类型提交文本

html - 最大设备宽度和方向变化

html - 如何使导航栏中的 Logo 居中

jquery - 仅使一个子类别在 bootstrap 和 angular 中崩溃

html - Bootstrap 移动不工作

jquery - 更改css :after class using jQuery的背景图片

css - "Float"没有 flexbox 的两侧居中元素?

jquery - 如何垂直动画菜单选项卡?

javascript - 最好将数组存储在本地存储或许多变量中?

html - 当内容框一分为二时,边框选项卡不会展开