[Resolved] Can page hero video play on mobile?

Home Forums Support [Resolved] Can page hero video play on mobile?

Home Forums Support Can page hero video play on mobile?

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #2036244
    Andy

    Hi there,

    I’m using this:
    https://docs.generatepress.com/article/page-hero-background-video/

    I noticed it only auto-plays on desktop and not mobile.

    I’ve seen other themes auto-play on mobile. Can I get it to auto-play on mobile too?

    Thanks

    #2036293
    Ying
    Staff
    Customer Support

    Hi Andy,

    The theme itself doesn’t have control of video autoplay or not.

    As far as I know, most mobile devices, including Apple iPhones, Apple iPads and many Android and Microsoft devices do not support the video autoplay feature so your video will not play automatically if a visitor is on one of these devices.

    You can try switch to twenty-twenty one theme to test if the issue still there.

    Let me know 🙂

    #2036417
    Andy

    Hi Ying,

    I thought that too! Then I saw this website on my phone and I was surprised beccause it autoplays on my iphone. Any idea how it’s autoplaying on phone?

    (pasted under private info)

    thanks!

    #2036506
    Ying
    Staff
    Customer Support

    Not sure if it’s gonna work, but give it a try:

    Change this:

    <video loop muted autoplay poster="URL/TO/poster.jpg" class="background-video">
        <source src="URL/TO/video.mp4" type="video/mp4">
    </video>

    to:

    <video playsinline loop muted autoplay poster="URL/to/poster.jpg" class="background-video"  >
        <source src="URL/TO/video.mp4" type="video/mp4">
    </video>

    Let me know 🙂

    #2036534
    Andy

    wow, you are a wizard Ying! That worked! I tested it on another client’s site and it plays perfectly on iphone. Thank you so much!

    #2036537
    Ying
    Staff
    Customer Support

    Awesome! Glad it works 😛

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.