Evenly Spaced Images in a Table?

Discussion in 'HTML & Website Design' started by eclipsemedia, Apr 3, 2009.

  1. #1
    I been frustrated trying to solve this.

    I need to have any amount of images (<img .....>) spaced evenly in a single table column (<TD>)

    Example
    <td width="779" align="center">
    <img src="pic1.jpg">
    <img src="pic2.jpg">
    <img src="pic3.jpg">
    <img src="pic4.jpg">
    </td>

    Right now I need to use Hspace in order to even out the spacing but its very time consuming as I need to test and test until it looks even.

    I tried using <DIV> tags as well but no such luck.

    Thanks
     
    eclipsemedia, Apr 3, 2009 IP
  2. Oxi

    Oxi Peon

    Messages:
    78
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Use css property margin?
    margin-bottom, margin-top, margin-left, margin-right, margin: int int int int

    Use as so:
    <img src="pic1.jpg" class="spaced">
    <style type="text/css">
    .spaced {margin: 5px 0px 5px 0px;}
    </style>

    or <img src="pic1.jpg" style="margin: 5px 0px 5px 0px;">
    (margin is in the form "top right bottom left")
    for just a few examples
     
    Oxi, Apr 3, 2009 IP