Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Hi!
I've added a video hero section to the Story Theme but it doesn't seem to be playing the linked video as background. Maybe there is a problem with the css.theme or something I should add.
Website: https://wwaca.myshopify.com/
Password: website
Hi @WearBasics,
To show video, you need to add embedded content. You can add this snippet in this class name "animation-cropper"
Please take a look at the screenshot here: https://prnt.sc/10ji6h9
<style>.embed-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; max-width: 100%; } .embed-container iframe, .embed-container object, .embed-container embed { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }</style><div class='embed-container'><iframe src='https://www.youtube.com/embed/_9VUPq3SxOc' frameborder='0' allowfullscreen></iframe></div>
I just added the snip but it still doesn't work. I would think there is something missing in the code.
Maybe you can give me a direct hand in the coding?
Hi @WearBasics,
So can you try this:
- In your file "theme.scss.liquid”, please paste this code:
.embed-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; max-width: 100%; } .embed-container iframe, .embed-container object, .embed-container embed { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }
- Regarding you module hero, please embed this video:
<div class='embed-container'><iframe src='https://www.youtube.com/embed/_9VUPq3SxOc' frameborder='0' allowfullscreen></iframe></div>
So please let me know when you finish or if you have any questions or need further support, I will help you.
Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024Hey Community! It’s time to share some appreciation and celebrate what we have accomplis...
By JasonH Nov 14, 2024