If you have html like this:
<img .../>
<img .../>
That actually looks like this to the DOM:
ElementNode(img)
TextNode
ElementNode(img)
The whitespace (newline, space, and tab) that occurs between the tags
collapses to a one space text node. The browser is correctly leaving
this space between your images.
As for how to fix it, there are a couple of approaches:
1) Eliminate the whitespace entirely
<img .../><img .../>
2) Enclose the whitespace as comments:
<img .../><!--
--><img .../>
dcm
On Apr 29, 2:56 pm, Mike <[email protected]> wrote:
> I'm having some difficulties removing spacing between images. I have a
> standard border margin and padding all set to 0. I have an img
> { border: none }.
>
> * { margin: 0; padding: 0; border: 0; }
>
> When I have two images side by side I'm getting space in between them.
> This happens in both IE and Mozilla. I can't figure out why it doing
> this.
> Please help
>
> Thanks
--~--~---------~--~----~------------~-------~--~----~
--
You received this because you are subscribed to the "Design the Web with CSS"
at Google groups.
To post: [email protected]
To unsubscribe: [email protected]
-~----------~----~----~----~------~----~------~--~---