Site logo

Archived topic

Single Post Image Border and Featured Image Shadow

14 replies · Started by Rohan Verma on August 27, 2020

Viewing posts 1–15 of 15

Hi team,

1. I want to implement this type of code for my single post images (single post image border). Should not be applicable for featured images.

.post-content img {
    border: 1px solid black;
}

2. Need featured image shadow effect on single posts and all featured image thumbnails.
Example Screenshot: https://prnt.sc/u6xql0

Hi there,

1. Try this CSS:

.entry-content img {
    border: 1px solid #000 !important;
}

2. I clicked on a few single posts and don't see a featured image in any of them.

This should work for the WPSP featured images:

.wp-show-posts-image img {
    -webkit-box-shadow: 10px 10px 5px 0px rgba(0,0,0,0.75);
    -moz-box-shadow: 10px 10px 5px 0px rgba(0,0,0,0.75);
    box-shadow: 10px 10px 5px 0px rgba(0,0,0,0.75);
}

You can tweak the shadow using this site:
https://www.cssmatic.com/box-shadow

The image shadow is working.

But the image border is applying for featured image. I don't to display border for featured image in single posts.

Check this article: https://www.gadgetheadline.com/turn-off-active-status-facebook-app-web/

Here I have shared multiple inner content images like screenshots. I want those inner images within a border. Not for the featured image.

One more thing. The archive and search result thumbnails don't have a shadow. How to get that?

This should work for search results:

.post-image img {
    -webkit-box-shadow: 10px 10px 5px 0px rgba(0,0,0,0.75);
    -moz-box-shadow: 10px 10px 5px 0px rgba(0,0,0,0.75);
    box-shadow: 10px 10px 5px 0px rgba(0,0,0,0.75);
}

Search and archive is fixed now.

But why you can't see featured image? Check this is the featured image for that post.

https://prnt.sc/u7m8ue

Yes. That's the featured image. And added from Features Image metabox.

What's wrong with it? Can you tell me.

Yes. Now, it's working fine. Thank you.

Can you guide me how can I use a featured image in middle of paragraphs according to my choice?

Can you open a new topic for the new question?

Thanks :)

This archived topic is closed to new replies.