Hippo notes 2

  • Carousel Parameters

Problem: In Hippo banner carousel setting, changing parameter height has no effect.

Solution: This is because missing configuration of CSS with parameter height in essentials-carousel.ftl.

The following code is a good example to show that using object from java bean to dynamically configure the CSS in script.

<#-- @ftlvariable name="cparam" type="org.onehippo.cms7.essentials.components.info.EssentialsCarouselComponentInfo" -->
<@hst.headContribution category="htmlHead">
<style type="text/css">
<#-- Carousel base class -->
.swiper-wrapper {
max-height: ${cparam.carouselHeight}px;
}
</style>
</@hst.headContribution>