search

Home  >  Q&A  >  body text

html5 - 如何在video显示第一帧

阿神阿神2785 days ago1039

reply all(2)I'll reply

  • 大家讲道理

    大家讲道理2017-04-17 13:44:44

    poster attribute
    In addition, some models of mobile phones do not support it, and ios needs to click to get the first frame.
    You can put an img on the video, and then put the poster's url in the img yourself. After the video is loaded, it will be displayed and the img can be hidden.
    Another method is to play the video by default, so you don't need to think about it. Whether to display the first frame.

    reply
    0
  • 怪我咯

    怪我咯2017-04-17 13:44:44

    <video controls="controls" preload="auto" id="video"></video>

    Upload successful callback

    function(videoUrl){
        $('#video').attr('src',videoUrl);
    }

    Try using the preload attribute of video

    reply
    0
  • Cancelreply