To Play movie in HTML File Pls. use the following steps
- First create a folder i.e. we create a folder named "Play movie with html code"
- Now add two files in this folder in which one file is movie file which is of any format like '.mp4', '..webm','.ogg' etc. and second file is '.swf' format. We used two files 'movie.ogg' and 'movie.swf'
- Now open a notepad file and paste the following code
<!DOCTYPE html>
<html>
<body>
<video width="320" height="240" controls="controls" autoplay="autoplay">
<source src="movie.ogg" type="video/ogg" />
<source src="movie.mp4" type="video/mp4" />
<source src="movie.webm" type="video/webm" />
<object data="movie.mp4" width="320" height="240">
<embed width="320" height="240" src="movie.swf" />
</object>
</video>
</body>
</html>
Now saved the above file with any name along with .html' extension. i.e. we used 'playmovie.html'
4 Now when we browse the 'playmovie.html' file in any browser then it play your movie.
Video play with HTML code
No comments:
Post a Comment
Note: only a member of this blog may post a comment.