close
解法:
在最外面的div中加上form-inline class即可!!
--
轉自 https://www.cnblogs.com/initx/p/11509959.html--
form-control 總是會換行,後面加單位的時候很難看,如下圖。
1 < div class ="col-sm-3" > 2 <輸入id ="investAmount" name ="investAmount" class ="form-control"必需 th:field ="*{investAmount}" type ="text" > 3 <選擇名稱="unit"類="form-control" th:field ="*{unit}" id ="unit" > 4 < option value ="萬元" >萬元</ option > 5 < option value="億元" >億元</ option > 6 </ select > 7 </ div >
嘗試了多種方法,終於發現在外框裡加入form-inline就可完美解決。
1 < div class =" form-inline col-sm-3" > 2 <輸入id ="investAmount" name ="investAmount" class ="form-control"必需 th:field ="*{investAmount}" type ="文本” > 3 <選擇名稱="unit"類="form-control" th:field ="*{unit}" id ="unit" > 4 < option value ="萬元" >萬元</ option > 5 < option value ="億元" >億元</ option > 6 </ select > 7 </ div >
--
文章標籤
全站熱搜
留言列表