• Hi,
    I’m currently using the Twenty Twelve theme and can’t seem to figure out how to center the featured image. I’ve tried modify the .wp-post-image and .attachment-post-thumbnail to margin: 0 auto. However, it does nothing.

    Any help is appreciated.

Viewing 7 replies - 1 through 7 (of 7 total)
  • No way to help with CSS without seeing your site.

    Thread Starter ndmccain

    (@ndmccain)

    It’s just the default Twenty Tweleve theme that comes with WordPress. My site isn’t live yet.

    IreneV

    (@irenev)

    In ‘Edit page’: click on the image, click on the left hand corner icon, choose Center, click Update.

    I wanted to post here in case someone else had trouble.

    The reason margin:0px auto; wasn’t working is because the featured image in 2012 has a display:inline; property to it. You can either add text-align:center; to your .entry-header class (which will center align everything) or, you can do this

    .entry-header img.wp-post-image {
    	float:none; clear:both;
    	margin-left:auto;
    	margin-right:auto;
    	display:block;
    }

    Hope that helps someone.

    Seen advice above, but I click on Featured Image and don’t get any choices. Can’t find the code above do attempt to adjust. Such a shame the featured image is over to the left and I want it centred like the text. Any further advice?

    Can you please post a link to your site? It’s always easier to suggest an answer when the site can be examined directly.

    I’ve pasted the pictures in, not as featured image, just as an image and then could center it. So nothing to show. But thank you for thinking. Denise

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Center Featured Image’ is closed to new replies.