SitePoint Sponsor

User Tag List

Results 1 to 5 of 5
  1. #1
    SitePoint Enthusiast
    Join Date
    Nov 2002
    Posts
    37
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    CSS ? about images

    i was wondering how to eliminate the spacing between images that are next to each other horizontally...i understand to eliminate spacing if stacked vertically ..
    .img {
    display:block; margin:auto;
    }

    but what do i put in to do it horizontally?

  2. #2
    Old Fogey mancroft's Avatar
    Join Date
    Oct 2002
    Location
    lost
    Posts
    445
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    dunno. why not weld the images together?
    :

    :

  3. #3
    SitePoint Evangelist
    Join Date
    Jul 2001
    Location
    UK
    Posts
    407
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Check the code:

    Code:
    <img> <img>
    to

    Code:
    <img><img>
    Might solve it?

  4. #4
    ********* Streaker Lister14's Avatar
    Join Date
    Jun 2002
    Location
    C:\Documents and Settings\Desktop\Recycle Bin
    Posts
    677
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    tried this already?

    <img border="0" padding="0"...>
    roy.lu
    C:\DOS... C:\DOS\RUN... RUN\DOS\RUN...!

  5. #5
    American't awestmoreland's Avatar
    Join Date
    Sep 2002
    Location
    Grand Rapids, MI
    Posts
    1,168
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    In my experience, some editors take whitespace and treat it like spaces. I picked up HTMLKit at the recommendation of someone on SPF. Great tool, but this does occasionally do this.

    Note how I closed the anchor tag in this code on the same line that I opened my IMG tag:
    Code:
    <a href=#
     onmouseover="button_hover_on(4)"
     onmouseout="button_hover_off(4)"
     onclick="button_click_on(4)"
     ><img id="But_Biography" border="0" src="nav_graphics\\Up_Biography.png"></a><br>
    Not very elegant, but if I start a new line with my IMG tag, then there is a gap between this image and the previous one. Presumably a space " " char.

    If you have all your code laid out neatly, try jamming it all together on one line with no spacing and see if that fixes the problem. If it does, then try formatting it bit by bit until you find the code that's causing the problem.


    Andy


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •