SitePoint Sponsor

User Tag List

Results 1 to 4 of 4

Thread: Tire of me yet?

  1. #1
    SitePoint Evangelist Barnum's Avatar
    Join Date
    Oct 2008
    Posts
    418
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Tire of me yet?

    Sorry to keep asking questions.... the captions on a few of my pages are not as close as I would like to the photo.
    Not sure what I did...they were right under the images this morning?

    Link is http://www.stoutstandards.com/Aboutme.html

  2. #2
    Life is not a malfunction gold trophysilver trophybronze trophy
    TechnoBear's Avatar
    Join Date
    Jun 2011
    Location
    Argyll, Scotland
    Posts
    6,177
    Mentioned
    264 Post(s)
    Tagged
    5 Thread(s)
    It looks fine to me. This is what I'm seeing:
    barnum.jpg
    Are you trying to close the gap further than this?

  3. #3
    Sploghm bronze trophy Victorinox's Avatar
    Join Date
    Nov 2008
    Posts
    749
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)
    Tables aren't the ideal method for laying out images and captions, and others may want to suggest alternatives, but a quick way to change the gap with your existing markup would be to add a class to the tables that will allow targeting the child imgs. At present, all imgs are set to have a 10px margin by this rule:

    Code CSS:
    img {
       border: 4px solid black; 
       margin: 10px;
    }

    So, to make a special case for tables that have images and captions in separate tds, give the tables a class such as class="image-and-caption" and add this CSS:

    Code CSS:
    .image-and-caption img { 
        margin: 0 10px 0; 
        vertical-align: bottom;
    }
    If the resulting gap is too small, adjust the last margin value from 0 to whatever suits.

    That's an interesting nut on your Gibson, by the way.

  4. #4
    SitePoint Evangelist Barnum's Avatar
    Join Date
    Oct 2008
    Posts
    418
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    Thank you both.....I wouldn't have come up with this solution, but I will do my best to remember it if I have the problem again. I need to take more classes. Love Sitepoint!


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
  •