Video as a hero header_No audio

Dear community,

I am using a video as a hero header on a landing page, but there is no audio. Is there a way to change this?

Thank you very much in advance!

With best regards,
Anastasiia

Hey,
We do not have any audio to the videos we upload (maybe it is from a local machine (upload), from CSS tags or from CDS).

If you want your video to have sound you can try using an iframe. In the source of the body you can use the iframe tag and link the video to the webpage. The video will have sound every time it is played.

I hope this helps.

Regards,
Prakhar

1 Like

Thank you, Prakhar!

Hi there

Just to add to Prakhar’s message above: If you go ahead and display video, please consider using a file format (e.g. .webm) that is as lightweight as possible. Including videos on websites tend to significantly increase loading times due to the additional content. You would want to make sure that the inclusion of videos does not negatively impact too many users.

Good luck!

1 Like

Thank you, Joachim! Well noted!

An instant follow-up on this: it looks like the .webm format is not allowed, and I cannot adjust the permitted formats in the structure. There might be a way I am simply not aware of, though.

Hi Anastasiia

You need to add support for .webm yourself, then. You do this through the Structure tab. Select the Content Type of interest, scroll to the relevant media, e.g. images, and add to the existing list. You can refer to the below screenshot as an example (reached via /admin/structure/types/manage/article/fields/node.article.field_image):

You obviously need to choose the field relevant for your website.

Thanks!

This is how I used to do it before, but now I don’t find the option in the Structure anymore to adjust video formats (when I go to the landing page content type there is just one component to adjust and then among the fields I can only chose ‚media‘, settings for which are non-adjustable.

Hi again

Any chance that the field has been removed? You can always (re)add the field and then specify the allowed file extensions. Which website is this?

Thanks!

Thank you for your quick reply, Joachim! It is quantum.cern