Title: Margin/Padding Issue around Image
Last modified: August 19, 2016

---

# Margin/Padding Issue around Image

 *  Resolved [proudtobedad](https://wordpress.org/support/users/proudtobedad/)
 * (@proudtobedad)
 * [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/)
 * Hi there,
    I’m using Modularity Lite, and am having an issue with margins around
   images. On my pages, the margins around photos look fine, but in my posts, the
   text runs right up to the image.
 * Any idea where I’d fix this? I’ve played around with most of the items on the
   style sheet, but nothing has fixed it.
 * Thanks!

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

 *  [jkovis](https://wordpress.org/support/users/jkovis/)
 * (@jkovis)
 * [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/#post-2056370)
 * WordPress adds the following classes to images it inserts:
 *     ```
       .centered
       .alignright
       .alignleft
       .alignnone
       ```
   
 * Can you post a link to your site?
 *  Thread Starter [proudtobedad](https://wordpress.org/support/users/proudtobedad/)
 * (@proudtobedad)
 * [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/#post-2056375)
 * Here it is. You’ll see on the home page that the photo and text run into each
   other, but on other pages, such as the “About/Bio” page, the images have a margin
   around them. I’d appreciate any help you can give!
 *  [jkovis](https://wordpress.org/support/users/jkovis/)
 * (@jkovis)
 * [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/#post-2056378)
 * It looks like the link didn’t post.
 *  Thread Starter [proudtobedad](https://wordpress.org/support/users/proudtobedad/)
 * (@proudtobedad)
 * [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/#post-2056382)
 * Oops–guess I must be pretty tired! 🙂
 *  [jkovis](https://wordpress.org/support/users/jkovis/)
 * (@jkovis)
 * [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/#post-2056385)
 * These two styles are overriding img.alignright:
 *     ```
       .home .size-medium, .home .size-large {
         max-width: 590px;
         height: auto;
         overflow: hidden;
         margin: 0 .55em .55em .65em;
       }
       .content .size-medium, .content .size-large {
         margin: 0 1.5em 1.5em 0;
       }
       ```
   
 * The easiest thing to do may be to add an !important statement to the margins 
   on img.alignright so it reads: `margin: 5px 0 5px 20px !important;`
 *  Thread Starter [proudtobedad](https://wordpress.org/support/users/proudtobedad/)
 * (@proudtobedad)
 * [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/#post-2056477)
 * Perfect! That did the trick!
 * Thanks so much!!

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

The topic ‘Margin/Padding Issue around Image’ is closed to new replies.

## Tags

 * [image](https://wordpress.org/support/topic-tag/image/)
 * [margin](https://wordpress.org/support/topic-tag/margin/)
 * [padding](https://wordpress.org/support/topic-tag/padding/)
 * [problem](https://wordpress.org/support/topic-tag/problem/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 6 replies
 * 2 participants
 * Last reply from: [proudtobedad](https://wordpress.org/support/users/proudtobedad/)
 * Last activity: [15 years, 1 month ago](https://wordpress.org/support/topic/marginpadding-issue-around-image/#post-2056477)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
