I want to display a user uploaded video in a custom module.
I added a video field, so the user is able to upload a video, but I cannot figure out how to access the source of that file, so I can include in the html.
The HTML currently looks like this:
<div>
<video class="header-video" playsinline autoplay muted loop>
<source src="{{module.background_video.src}}" type="video/mp4">
</video>
</div>
because a similar approach had worked for images, but here the src is just empty. I assume “module.background_video.src” is not correct, but I tried also tried several other possibilities, none worked and I cannot find any helpful documentation that addresses how to use the video module.
The video field is called ‘background_video’.