d.ariel d.ariel - 1 month ago 7
CSS Question

Wordpress twentysixteen theme removing all the unnecessary spacing in theme

Basically this is one question but might need a multi part answer to remove the excess spacing. Basically the problem occurs when setting the featured image on a post on the default twentysixteen theme. I have a live test environment setup to show this here: http://192.241.239.174/index.php/2016/11/02/hello-world/

Here is a shot of how it currently is vs what I'm expecting it to look like: http://prntscr.com/d204p5

Thank you for any help

Edit: Further researching similar questions I have gotten slightly closer by using some custom css to change the thumbnail/featured image max width to 150 which should be fine as all my featured images are going to be 150x150 anyways. This code was added into custom css:

.post-thumbnail img {
float: left;
margin: 5px 15px 10px 0;
max-width: 150px;
}


Now the text does appear slightly higher but still fails to wrap the thumbnail and is still not close enough to the thumbnail. I'd like to have the text closer to the thumbnail

EDIT: Complete solution
The complete solution I used was adding this code into my custom css:

.entry-footer {
display: none;
}

.post-thumbnail img {
float: left;
margin: 0px 20px 0px 0;
max-width: 150px;
}

body:not(.search-results) article:not(.type-page) .entry-content {
float: none !important;
width: 100%;
}


.entry-content > :last-child {
margin-bottom: 0;
text-align: center;
width:100%;
}

Answer

i don't think that's the better choice to make in fact i would have setup a child theme and worked on it, by the way:

.entry-footer {
    display: none;
}

.post-thumbnail img {
    float: left;
    margin: 0px 20px 0px 0;
    max-width: 150px;
}

body:not(.search-results) article:not(.type-page) .entry-content {
     float: none !important; 
     width: 100% !important;
}

.entry-content > :last-child {
    margin-bottom: 0;
    text-align: center;
}

You may need to add !important keyword if something doesn't work. The result: Is that like what you wanted?

Comments