Source: Jurrie Eilers, sticky blogposts sidebar and sticky widgets on the blog index.
https://www.zelfkennis.nu/blogboek/
@media (min-width: 981px) {
.et_right_sidebar #sidebar, .et_pb_widget_area {
position: fixed;
right: 5%;
top: 21%;
max-width: 30%;
}
}
Code language: CSS (css)
Of een 2e manier, ook van Jurrie. Werkt fantastisch in chrome, firefox en safari.
.stickthis {
position: sticky;
top:40px;
}
Code language: CSS (css)
Alternatives
- On the advanced tab of a Divi element, set Position to Fixed.
- Plugin “Sticky Menu (or Anything) on Scroll