BootStrap表單寬度設定方法,bootstrap表單

來源:互聯網
上載者:User

BootStrap表單寬度設定方法,bootstrap表單

用bootstrap的柵格“ coll-md- ”命令設定寬度總是不盡人意,有時上下框對不齊,有時上下寬度又不齊,這時建議用“style="width:100px" "

<div class="page-header">   <form class="form-horizontal" >     <div class="form-group form-group-lg">      <label class="col-sm-2 control-label no-padding-right"style="float:left;font-size:1em; font-family:Microsoft YaHei;"for="form-field-userName1">轉運聯單號</label>         <div class="col-sm-4">           <input class="col-xs-12 col-sm-10" type="text" id="mission_id"placeholder="請輸入關鍵字搜尋"/>         </div>    </div>   <form><div>

2.或者人用style屬性

<form class="form-horizontal" >     <div class="form-group">      <label class="col-sm-1 control-label no-padding-right"style="width:180px;font-size:1em; font-family:Microsoft YaHei;"for="form-field-userName1">任務單號:</label>        <div class="col-sm-4">         <input class="col-xs-12 col-sm-10" type="text" id="form-field-userName1"placeholder="請輸入關鍵字搜尋"/>       </div>     </div></from>

對比可以看出來,使用第二種方法更加整齊些。

本人bootstrap剛入門,只是在做項目時遇到的問題和解決方案寫下來,可能有時是錯誤的,請大家多多指教。如果大家有任何疑問請給我留言,小編會及時回複大家的。在此也非常感謝大家對幫客之家網站的支援!

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.