If the video is short you might want to have it replay automatically. In this video, learn how to apply the loop attribute and, more importantly, where and when to apply it.
- [Instructor] Our final exercise in this chapter…answers a common question.…My video is really short, can I loop it?…The answer is, yes, there is an attribute for that.…And to get yourself started, open the looping.html file…found in your chapter download.…The first thing you will notice is a change in the video.…Right here, it's AsilomarShort.…This is a five-second version of the clip…which I'm going to use to demonstrate a loop.…Now what you do is you add a loop attribute…right at the end of the video element.…
So you just type in loop, and if you save it,…and test in the browser,…I'm just gonna turn up the audio here,…you see, there's the five seconds.…And it just loops, okay, so I just watch it loop.…Here it comes up to the end, and it starts again.…And it just keeps looping until you stop it.…So let's come back to Brackets.…So what this attribute does is…to simply restart the video when it is finished playing.…
This one is rather dangerous,…because it will continuously play and replay the video…until the user either leaves the page or quits the browser.…
- Key video formats used to publish on the web
- Encoding video that's optimized for online delivery
- HTML5 native video embedding and interaction
- Styling video components with CSS
- Captioning video
- Preparing video for social media
- Using Dynamic Link
Skill Level Beginner
Design the Web: HTML Background Videowith Chris Converse28m 35s Intermediate
Web Video: Develop Your Video Presencewith Rick Allen Lippert41m 54s Intermediate
Web Video: Makeup Techniqueswith Rick Allen Lippert25m 47s Intermediate
Exercise files1m 11s
1. Web Video Formats
2. Encoding Video
3. HTML5 and Video
4. Video and CSS
5. Playing with Video
Next steps1m 23s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.