0
我已經在div中創建了3個輸入框,並且輸入框已經被設置爲具有269px的寬度,但是當我在瀏覽器中查看它時顯示額外的2px,我該如何阻止它。我在右邊設置了5px的邊距,但在第三個邊上設置爲0。具有額外寬度的輸入
input {
text-indent: 5px;
height: 45px;
color: #ffffff;
width: 269px;
margin-right: 5px;
background-color: #0A4E6E;
border: none;
font-family: Helvetica Neue;
font-size: 22px;
display: block;
float: left;
}
請提供HTML部分。 – Arbel 2013-04-09 20:39:15
當然不是DIV? – Limey 2013-04-09 20:39:55
設置'input {box-sizing:border-box};'add'-moz','-webkit'如果需要 – David 2013-04-09 20:41:13