Archived topic
Padding around images
6 replies · Started by Mario on November 25, 2021
Hi
I'm new to generatepress/blocks and i'm trying to figure out how to put padding around in content images (in posts). Do i need to put an image inside a container to be able to add padding?
I saw a few related questions on the forum where css was provided but i want to be able to position each image inside a post seperately.
More specifically, I have lots of posts (i'm coming from Thrive) that have 7 images left aligned with text to the right of them and in Thrive Architect i would then add 30px padding between the image and the text and also use top and bottom padding/marging to position each image so it aligns at the top or bottom of the paragraph thats to the right of the image
Is there a way to control padding around each image within a post...?
Thanks,
Mario
Hi Mario,
Any chance you can link us to the site in question and show us where to look at?
You can use the private information field.
https://docs.generatepress.com/article/using-the-premium-support-forum/#private-information
Let me know :)
Hi Mario,
Any chance you can link us to the site in question and show us where to look at?
You can use the private information field.
https://docs.generatepress.com/article/using-the-premium-support-forum/#private-information
Let me know :)
Hi Ving,
The site with GP is in a staging environment and passwordprotected. Here is a link to the live site to a post where i have images to the left of paragraphs as an example. Each of those images has its own padding values and thats what i'm trying to do in GP/ Blocks now...
The live site is still running on Thrive Themes...
- https://www.avidpup.com/best-food-for-corgi-puppy/
Thanks
Are we talking about this part:
https://www.screencast.com/t/kud3rNIr
If so, GP doesn't have the control of the detailed content in each page/post, so no, there's no such control allows you to specify the margin around the image. It's more like a page builder/ block editor's setting.
You'll need to use CSS or find a specific plugin for it.
So there's no way to do this with Generateblocks? How bout putting an image inside a container or grid and then use padding around the container? Like i said i'm totaly new to GP and GB and like to do it in the most efficient way / without adding unnecessary code...
How bout putting an image inside a container or grid and then use padding around the container?
Ah, yes, that's a good way. You can do so and add a custom class to the container block, eg, float-container, then add this CSS:
.float-container {
float: left;
}