WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Can't Center Image After WordPress Upgrade (3 posts)

  1. 50by25
    Member
    Posted 7 months ago #

    At some point in the last month or two, images that were centered on my blog (which is my default) no longer show up as centered - unless they have a caption. I've looked into the CSS and tried some suggestions I had found (adding a float: center, changing margin-left and margin-right to auto, even adding a text-align: center to the class), but nothing seems to be working.

    The class in question seems to be imgcentered:

    img.centered, .aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;

    And here's a page on my site that has an image with no captions: http://www.50by25.com/2014/07/reviewgiveaway-adora-calcium-supplements.html

    For comparison, here's the class for captions:

    .wp-caption {
      padding: 0;
      text-align: center;

    And here's a page on my site that has images with captions: http://www.50by25.com/2014/07/weekend-recap-fitness-on-the-rocks.html

    How do I get regular images with captions to center?

  2. Andrew
    Forum moderator
    Posted 7 months ago #

    50by25 says:

    Hooray!! Just did more digging and figured out that it was an issue with a Pin-It plug in. Solution here for anyone else:

    https://github.com/canha42/pinterest-pin-it/issues/58#issuecomment-50097961

    I would link the thread that I extracted that quote from, but the thread is irrelevant.

  3. 50by25
    Member
    Posted 7 months ago #

    Thanks for cross-posting this - you read my mind :)

Reply

You must log in to post.

About this Topic