user3766722
user3766722

Reputation: 89

How to add thumbnails for embed video in website(Squarespace)

I have embed some video to my website using following code.

<div id="container">
<video loop autoplay="autoplay" />
    <source id="mp4" src="/s/test.mp4" type="video/mp4" />
</video>
</div>  

When entering into my site the video taking few seconds to load. And the background is black, its not looking fair. No problem if internet speed is good, otherwise its display black background for few seconds. So how to add thumbnail while loading video or adding text called"video loading".

Upvotes: 2

Views: 1674

Answers (1)

joshweir
joshweir

Reputation: 5617

Use the tag id poster

<video controls="controls" poster="/IMG_LOCATION/IMAGENAME">

More info can be found http://www.w3schools.com/html5/att_video_poster.asp

I found this here: How to make a loading image when loading HTML5 video?

If that doesn't work see the first answer on that page - where you could show the loading image using some javascript but this solution worked for me.

Upvotes: 1

Related Questions