I am trying to play a mp4 video on my HTML page, I have searched the web and found that in HTML5 I can do this with video
tag like this below
<video width="320" height="240" autoplay>
<source src="movie.mp4" type="video/mp4">
</video>
Issue I am facing
- My main issue is my video is stored in my local computer in some location, So how can I call that from that path
- In my system it is located in
D drive
so I want to call it from there - I am new to this so I don't know if I am doing it the right way; is my approach correct?
- My requirement is to auto-play video on my web page
I am doing like this
<video width="320" height="240" autoplay>
<source src="D:\Video\samplevideo.mp4" type="video/mp4">
</video>
D:\Video\samplevideo.mp4
is the path of my file and samplevideo.mp4
is the name of the video
On Chrome it show error Not allowed to load local resource: file:///D:/Video/samplevideo.mp4
And on Firefox All candidate resources failed to load. Media load paused.
Edit
My main focus is to play video on webpage.
I need to play a video on the web (HTML page) when page is loaded I have that video in my system at D:\Video\samplevideo.mp4
this path, how can I play that video when page is loaded.