使用CSS删除图像之间的空间 [英] Use CSS to remove the space between images

查看:117
本文介绍了使用CSS删除图像之间的空间的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

给定:

<img src="..."/>
<img src="..."/>

结果是两个图像之间有一个空格。看来,正常的行为是将任意数量的空格,换行符和制表符显示为单个空格。我知道我可以做以下:

The result is two images with a single space between them. It seems that the normal behavior is to show any number of spaces, newlines, and tabs as a single white space. I know I can do the following:

<img src="..."/><img src="..."/>

<img src="..."/><!--
--><img src="..."/>

<img src="..."/
><img src="..."/>

或任何其他黑客。有没有办法用CSS删除空格?例如

Or any number of other hacks. Is there a way to remove that whitespace with CSS? e.g.

<div class="nospace">
    <img src="..."/>
    <img src="..."/>
</div>


推荐答案

让他们

这篇关于使用CSS删除图像之间的空间的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆