Site logo

Archived topic

Help needed with formatting blog page items

5 replies · Started by Stephen on September 30, 2018

Viewing posts 1–6 of 6

Hi

I am new to GP and Wordpress. I am trying to change formatting, border, padding etc of the tiles in the blog page but would appreciate some general help in how to do this as without extra styling it doesn't look very good.

I've been trying to paste style info from the chrome dev tools window but the styles get applied to other pages as well.

I think I'm at the end of my tether and close to asking for a refund!

thanks

Steve

Hi Steve,

The posts page has the blog tag in body class.

For example, if you use

.blog .inside-article, .archive .inside-article {
    border: 2px solid #000;
}

Then it will only apply to the blog and archive page.

Let me know if this helps :)

If not, any chance you can link me to the site and let me know exactly what style you are trying to add?

Hi Leo, thanks for this seems to be working great.

I think I'm missing some tricks here as I can't see .blog in the node tree in the chrome inspector.

I've been trying to format other blog items by copying style info from the inspector, can you suggest better alternatives for the following which I'm using to format excerpt text, heading and images:

div.post-image img{border:1px solid}
.generate-columns-activated.post-image-aligned-left .generate-columns-container article:not(.featured-column) .post-image{text-align:left}
div.entry-summary{text-align:justify;margin-top:10px}
.post-image-above-header .inside-article .featured-image, .post-image-above-header .inside-article .post-image{margin-bottom:10px}

Just one more query for the moment, is there a way to always display the "Read More" button even if there is an manual excerpt, as it only seems to display a read more button if the excerpt has been auto generated.

If there was a way to display the read more button as a link rather than a button that would be good too.

thanks for your help

Steve

Hi there,

If the CSS works thens it good :) But you could trim it back a little e.g:

.post-image img {
    border: 1px solid
}

]article:not(.featured-column) .post-image {
    text-align: left
}

.entry-summary {
    text-align: justify;
    margin-top: 10px
}

.post-image-above-header .inside-article .featured-image, .post-image-above-header .inside-article .post-image {
    margin-bottom: 10px
}

this topic covers the Read More

https://generatepress.com/forums/topic/read-more-button-after-excerpt/#post-653852

Hi David

thanks for the help.

Steve

You're welcome

This archived topic is closed to new replies.