Hello,
I’m currently using Hugo v0.126.2. Can someone tell me how I can embed a local mp4 video file and control the size of the embed on my site?
I searched around and found information on setting up shortcode, since my theme has no instructions on embedding video, but there doesn’t seem to be an option on controlling the size from the article I read.
Thanks.
When I search this forum for “video shortcode”
https://discourse.gohugo.io/search?q=video%20shortcode
I see a tips and tricks article written by @frjo
https://discourse.gohugo.io/t/42264
And that article points to
https://github.com/frjo/hugo-theme-zen/tree/main/layouts/shortcodes
And one of those shortcodes is for video:
https://github.com/frjo/hugo-theme-zen/blob/main/layouts/shortcodes/video.html
It works great.
{{< video
src="Big_Buck_Bunny_1080_10s_5MB.mp4"
width="600"
>}}
Yes! That worked.
The article I had found on the interwebs has short code for the shortcode. What you found was more thorough and much worked better. Thank You!
This forum has close to 20,000 topics. Search here first.
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.