Skip Navigation

[Resolved] 2 images per slide (horizontally) in a slider

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

This topic contains 3 replies, has 2 voices.

Last updated by Christopher Amirian 7 months, 1 week ago.

Assisted by: Christopher Amirian.

Author
Posts
#2697106

I want to display 2 logos of partners (post featured image) per page in a slider.
When I say "Display 2 items per page" in the pagination options, I am getting the 2 logos on top of each other. But I want them to be side by side (horizontal).

And I want the logos to be displayed horizontally centered, not left-aligned.

I somehow simply don't manage to get this done?

(i'm working in the classic views editor)

#2697281

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

This will need custom css coding to achieve the view you want.

I might be able to come up with a starting point for you. Would you please share the link that contains the 2 images so I can check?

Thanks.

#2698090

Thank you, I have created a test page: hidden link

Some other point is the height: While I indicate a fixed height in the shortcode, the height of the block is varying. How can I *really* fix the height of the whole slider (block)? (and vertically center the images)

Thank you!

#2698461

Christopher Amirian
Supporter

Languages: English (English )

Hi there,

You can use the CSS code below to get started with the styling that you want:

#wpv-view-layout-3179-CATTRce7465e89f161b0e2f792b9528eabe9f {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100%; /* Ensure the parent div takes the full height of its container */
}

#wpv-view-layout-3179-CATTRce7465e89f161b0e2f792b9528eabe9f > div {
    flex: 1;
    max-width: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
}

Please consider the code above is not meant to be a final solution as providing custom coding is outside of our support scope.

This is meant to be a starting point that you can build on if you want to fine tune the styling of the slider.

Thanks.