- This topic has 13 replies, 3 voices, and was last updated 8 years ago by
Tom.
-
AuthorPosts
-
March 20, 2018 at 7:13 am #524486
Kevin
I want it only on the mobile the images full appearance. 100% wide! No margins or padding.
The big problem is that if I try to change it the way I know. The text increases along with the image. I just want images to go beyond that blank on mobiles like adsense ads do.
An Image of how it is and how I want it:
March 20, 2018 at 9:54 am #524699Tom
Lead DeveloperLead DeveloperYou could do this:
@media(max-width: 768px) { .post-image { margin: -15px -25px 25px -25px !important; } }However, it will only work if your images are wide enough. Right now they likely aren’t, so they won’t reach the sides.
March 20, 2018 at 10:01 am #524704Kevin
I put this code but it did not change anything … I cleared the cache and tried several times … I do not think the article images have the post-image attribute when looking at the source code of the page.
March 20, 2018 at 12:42 pm #524824Leo
StaffCustomer SupportDid you make sure the images are wide enough as Tom mentioned above?
March 25, 2018 at 2:15 am #529826Kevin
750×350
March 25, 2018 at 2:17 am #529828Kevin
750×350 |||| it looks like the code you sent me changed only the prominent images within the categories and home.
March 25, 2018 at 9:15 am #530144Tom
Lead DeveloperLead DeveloperThe images are set to 375px wide: https://www.screencast.com/t/uUWYAE0oz
Perhaps that’s the width you have set in the Customizer?
If you go down small enough, you can see that it’s working: https://www.screencast.com/t/dfT3aiBAO0
March 27, 2018 at 11:46 am #532809Kevin
As I said, these images are miniature, I want the images inside the article to stay the way they… problem they do not have the post-image .css attribute.
They have only the img attribute, but if I do it goes with CSS going to bug everything images, and if I change the container it will take the margin of the texts beyond the image.
March 27, 2018 at 11:47 am #532810Kevin
Summing up! I want the images inside the post to stay that way.
March 27, 2018 at 9:33 pm #533213Tom
Lead DeveloperLead DeveloperSo you’re trying to target the images inside the full post?
If so, you can replace
.post-imagewith.featured-image.March 28, 2018 at 1:29 am #533420Kevin
but .featured-image does not reference only the featured image at the top of the article?
March 28, 2018 at 9:50 am #534066Tom
Lead DeveloperLead DeveloperYes, that class is only for the featured image.
If you’re wanting to do this to all images within your posts, you would have to wrap them in a div with a class, then apply that CSS to the class.
March 28, 2018 at 10:09 am #534090Kevin
Is not there a way to make all the images inside the post get wrapped up in a div like they did with video iframes? With a code in functions.php?
March 28, 2018 at 9:17 pm #534567Tom
Lead DeveloperLead DeveloperMaybe something like this?: https://wordpress.stackexchange.com/a/36014/90661
-
AuthorPosts
- You must be logged in to reply to this topic.