这里的风格:
html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img,
ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr,
th, td { margin: 0; padding: 0; border: 0; outline: none; list-style: none; }
body {
width: 100%;
height: 100%;
margin: 0;
padding: 0;
}
li {
width: 30.3%;
margin: 10px 1% 10px 1%;
padding: 0.5%;
float: left;
background: #000;
}
li img { width:100%; }
这是html:
<a href=""><li><img src="/images/test.png" /></li></a>
<a href=""><li><img src="/images/test.png" /></li></a>
<a href=""><li><img src="/images/test.png" /></li></a>
<a href=""><li><img src="/images/test.png" /></li></a>
<a href=""><li><img src="/images/test.png" /></li></a>
<a href=""><li><img src="/images/test.png" /></li></a>
如果您自己尝试,图像左侧有少量像素,这真的让我很生气。我已经尝试过 inline-block 并且它仍然存在。
任何帮助将不胜感激!