How to add video in html? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How to add video in html?

9th Aug 2017, 2:20 AM
Mr_Yaman
Mr_Yaman - avatar
9 Answers
+ 5
Youtube videos cannot be linked with <video> html5 media elements, as youtube doesn't provide direct link to hosted video, but only web page access to it. Youtube videos require to be integrated with an <iframe> element: check this link explaining how to, step by step: https://www.w3schools.com/html/html_youtube.asp
9th Aug 2017, 10:33 AM
visph
visph - avatar
+ 2
work for youTube videos too?
9th Aug 2017, 2:39 AM
Mr_Yaman
Mr_Yaman - avatar
0
make sure the video is in the same folder as the page, you then use the video src tag and the video name.
9th Aug 2017, 2:35 AM
Ibejih
Ibejih - avatar
0
<video> tag
9th Aug 2017, 7:30 AM
Learnsolo
0
It is not possible to do it in HTML but in the latest version HTML5 it can be done using <video> tag. It support 3 types of videos which are mp4, webm and ogg. The code to add a video is_ < video width="320" height="240" controls> <source src="movie.mp4" type="video/mp4"> <source src="movie.ogg" type="video/ogg">
10th Aug 2017, 11:45 AM
Safinaz Sayed
Safinaz Sayed - avatar
0
Good morning I want to display youtube vidéo like this I have error https://code.sololearn.com/WdFFV5IuLnwO/?ref=app
30th Aug 2022, 7:24 AM
Malick Diagne
Malick Diagne - avatar
- 1
yea
9th Aug 2017, 2:48 AM
Ibejih
Ibejih - avatar
- 1
if only u could link the particular page/name of the video
9th Aug 2017, 2:48 AM
Ibejih
Ibejih - avatar
- 1
rwet
21st Dec 2020, 6:09 AM
Adarsh Tiwari
Adarsh Tiwari - avatar