Skip to content

Instantly share code, notes, and snippets.

@rocketxujia
Created March 26, 2014 08:20
Show Gist options
  • Save rocketxujia/9778795 to your computer and use it in GitHub Desktop.
Save rocketxujia/9778795 to your computer and use it in GitHub Desktop.
ie下input输入框的padding特殊性修复
.block{
float:left;
}
.input-wrap{
display: inline-block;
width: 180px;
border: 1px solid red;
}
.input-wrap input{
margin-left: -20px;
width: 180px;
padding-right: 20px;
padding-left: 20px;
}
<div class="block">
<span class="input-wrap">
<input type="text" />
</span>
</div>
// alert('Hello world!');
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"all"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment