我把两幅图像垂直放在一起,但是有一个缺口,我尝试了一切,但我找不到什么是错的? 在这个网站上(左下黄色图像), http://www.jamesxu.com.au/contact为什么两个垂直图像之间有间隙?
HTML
<div class="pic_wrap">
<img id="contact" src="http://www.jamesxu.com.au/wp-content/themes/BLANK-Theme-realone/images/contact_01.png">
<a class="email" href="mailto:[email protected]"> </a>
<a class="message" href="http://www.jamesxu.com.au/contact/"> </a>
</div>
CSS
.pic_wrap {width:216px; margin:auto;}
a.email {background:url(images/ico.png) left -80px no-repeat; display:inline-block; width:216px; height:35px; line-height:0; font-size:0;}
a.email:hover {background:url(images/ico.png) left -120px no-repeat ; }
a.message {background:url(images/ico.png) left -164px no-repeat; display:inline-block; width:216px; height:45px; line-height:0; font-size:0;}
a.message:hover {background:url(images/ico.png) left -208px no-repeat ;}
该网站不可访问,而是尝试在两个元素取出填充和边框...('填充:0;边界:0 ;') – Kroltan
你应该总是在问题中包含相应的'html'code,而不仅仅是链接到你的页面。否则,如果你解决了你的问题或者你的页面消失了,那么你的问题就不会像其他人那样有帮助。 –
对不起,我尝试从我的主题中提取HTML,但不起作用。所以,只需在这里放置CSS。 –