single image equal dimension

  • Kleszewski
  • Kleszewski's Avatar Offline Topic Author
  • Platinum Member
  • Platinum Member
  • I like playing chess.
  • Posts: 527
  • Thanks: 16

single image equal dimension was created by Kleszewski

Posted 3 years 10 months ago #56291
hi
Elements -> Row -> Single image :
Is there any way for a single image so that the photos added here have the same dimension in each position of the added single photo. I mainly mean the height of the photo
If at the beginning their dimensions are different.

Please Log in or Create an account to join the conversation.

Replied by ced1870 on topic single image equal dimension

Posted 3 years 10 months ago #56304
Hi
you can do that using custom css like this
- add a css class on the row : equalimage

- add the custom css in the page
Code:
.equalimage .innercontent, .equalimage .cktype, .equalimage .imageck, .equalimage .imageck img { height: 100%; } .equalimage .imageck img { object-fit: cover; }
CEd

Joomlack Webmaster and Developer

by ced1870
Attachments:
The following user(s) said Thank You: Kleszewski

Please Log in or Create an account to join the conversation.

  • Kleszewski
  • Kleszewski's Avatar Offline Topic Author
  • Platinum Member
  • Platinum Member
  • I like playing chess.
  • Posts: 527
  • Thanks: 16

Replied by Kleszewski on topic single image equal dimension

Posted 3 years 10 months ago #56305
HTML / CSS button
class: equalimage


Template creator-> parameters -> custom css ->
Code:
/*single image resize*/ .equalimage .innercontent, .equalimage .cktype, .equalimage .imageck, .equalimage .imageck img { height: 100%; } .equalimage .imageck img { object-fit: cover; }
It's almost good :)
This message contains confidential information
Last Edit:3 years 10 months ago by Kleszewski
Last edit: 3 years 10 months ago by Kleszewski.

Please Log in or Create an account to join the conversation.

Replied by ced1870 on topic single image equal dimension

Posted 3 years 10 months ago #56310
just checked your url and the images have the same height :)

Joomlack Webmaster and Developer

by ced1870

Please Log in or Create an account to join the conversation.

  • Kleszewski
  • Kleszewski's Avatar Offline Topic Author
  • Platinum Member
  • Platinum Member
  • I like playing chess.
  • Posts: 527
  • Thanks: 16

Replied by Kleszewski on topic single image equal dimension

Posted 3 years 10 months ago #56311
almost equal ;)
Check once again
I have duplicated this element with the css class: .equalimage
Row container dupicate -> css.equalimage ->
I added photos of various sizes, without prior preparation, it came out what you see.

I know that the best solution is to prepare photos of equal dimensions, but I thought that since there is a mechanism in the gallery that scales the photos (crop image), maybe the same technique can be used here

Please Log in or Create an account to join the conversation.

Replied by ced1870 on topic single image equal dimension

Posted 3 years 10 months ago #56312
thanks, I see now :)
please try to add the width 100% like this
Code:
.equalimage .imageck img { object-fit: cover; width: 100%; }

Joomlack Webmaster and Developer

by ced1870

Please Log in or Create an account to join the conversation.

Time to create page: 0.805 seconds

Fast and powerful creation, customizable and responsive.

Read More

We have 1650 guests and one member online