Background Video covers multiple sections
I created a page with multiple sections. On the top section (my hero section) i want a video background.
On the second section I want a black background (without video) but the video selected in the first section wil cover all the section afterwards.
- Add a section
- Add a background video
- set the hight of section 1 to 600px
- Add multiple sections below the first one
- Add some random content
- View the result
- WordPress version: 6.2.2
- Cwicly Plugin version: 18.104.22.168.3
I recommend setting
overflow: hidden on your hero section, that should achieve what you want.
Thanks for your reply,
Unfortunately it doesn’t solve the problem.
@Lijn-B, please set
position: relative; on your hero.
Try adding position relative to the hero section (the one you have the background video set on). You normally don’t have to do that, but it will rule it out if it’s still overflowing. Without being able to inspect the site, it’s hard to tell what’s happening.
On another note, I would advise against setting hard pixel values for height in most cases, and let the content and padding adjust the height for you. If you must set a manual height, set it using the VH unit in the min-height field. This will allow things to stay fluid, where a fixed pixel value is really hard to control for section height in a responsive environment. For example, the content will start wrapping and stacking as the screen width shrinks and can easily overflow the container if you’re not careful. It’s also not future proof when you need to add or change content in the future. Just FYI.
Yes thanks that did the trick!!