A
A
Alexey Korolev2021-11-04 01:13:02
Bootstrap
Alexey Korolev, 2021-11-04 01:13:02

How to stretch the image to the width of the block with the specified padding property?

The idea is to stretch the pictures in the body to the width of the block. Given the features of the CMS, you can change the parameters only through img.
I tried this, but the picture just sticks to the left side and that's it.

.img-fix img {display:block;width:100%;height:auto;margin:0px -64px !important;}


618307c697d95532099472.png

The parent container has card card-body and p-3. How to be?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Pavel-ww, 2021-11-04
@Pavel-ww

A link to the page would help you more. And so you have to guess.
Add to the fact that you have height: 100%; , some min-height may be required, object-fit: cover;
Although I'm not sure it will work. Doesn't CMS have the ability to add custom CSS? Here you need to work on the parent

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question