Site logo

Archived topic

How to add category in blog page

5 replies · Started by Dipak Singh on August 4, 2021

Viewing posts 1–6 of 6

Hello team GP, I have tried a CSS

.blog-layout-1 .post-content .cat-label {
line-height: 1.5;
position: absolute;
top: 0;
left: 0;
font-size: 11px;
background: #000;
padding: 4px 12px;
margin: 0;
color: #fff;
text-transform: uppercase;
font-weight: 700;
text-align: center;
z-index: 10;
}

to show my category under blog page image left side top but it's not working.

Is there any way to solve this?

Hi there,

can you share a link to your site so i can see if that is possible.

Sure David, Please check this.

Try this CSS:

body:not(.single) .inside-article {
    position: relative;
}

body:not(.single) .cat-links {
    position: absolute;
    top: 25px;
    padding: 5px;
    background: #000;
}
@media(max-width: 768px) {
    body:not(.single) .cat-links {
        top: 15px;
    }
}

body:not(.single) .cat-links a {
    color: #fff;
}

body:not(.single) .cat-links .gp-icon {
    display: none;
}

I'm really so thankful to you.
Hats off.

Glad to be of help!

This archived topic is closed to new replies.