• Hello,

    Here’s my page: http://www.achieveitcoaching.com/

    I’m trying to alight the Recent Posts and Recent Comments at the bottom of the page with the image that’s next to it.

    It’s aligned but I want the image to be aligned with the top of the text not the bottom, how can I make it go higher?

    I’m using “Widgets on Pages” to insert the widgets into the page content.

    Any ideas are welcome, thanks.

Viewing 9 replies - 1 through 9 (of 9 total)
  • Why are you using tables for layout? That’s really not good practice.

    Hopefully you are not modifying theme files – as your changes will be lost when the theme is updated. You should be using a Child Theme or custom CSS.

    The alignment question is due to CSS on the table – once you’ve set up custom CSS or a child theme, try adding this:

    .entry-content td {
       vertical-align: top;
    }

    That might have other consequences, so do test it.

    Thread Starter anne29

    (@anne29)

    Wow you’re a genius, that made the image go up, but now the “Recent Posts” looks a bit lower, is there something I can modify for that as well?

    Thanks for the tips, I’ll be sure to lookup making a child theme once I’m done this this.

    There’s not going to be a way to apply that to one table cell and not another – that’s another reason to not use tables for layout.

    Also, making a child theme later is going to require redoing some of your work – so better to do it before you start doing any work on a site…

    Thread Starter anne29

    (@anne29)

    Ok. So if I don’t use the table there, how else can I format it?

    Actually, this CSS will work on that image:

    img.wp-image-268 {
       margin-top: 20px;
    }

    BUT CSS is still a much better way to do layout…you can use divs and float to position them.

    Andrew Nevins

    (@anevins)

    WCLDN 2018 Contributor | Volunteer support

    Thank you AN 🙂 – was just looking around for some of those articles…LOL!

    Thread Starter anne29

    (@anne29)

    Hello, thanks for your reply.

    What do I put instead of img.wp-image-268? I added that to the stylesheet but it didn’t do anything, I suspect I have to link it to that image specifically or what?

    Thanks

Viewing 9 replies - 1 through 9 (of 9 total)

The topic ‘Top-Aligning Text With Image’ is closed to new replies.