Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: HTML
how can I add video to html page???
Do I need to convert a video in a specific format???
Posted 8-Jun-12 4:49am
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Upload the videos to the server or for testing purpose in the folder on your computer where your html files are then use any of the two tags given below:
 
<embed src="myvideo.avi" />
 
or
 
<object data="myvideo.avi" />
 
in your html file. replace the src or data which ever applicable to the name of your video e.g your video name is holiday.mp4 so src="holiday.mp4" or data="holiday.mp4". About conversion to specific format, not necessary if your video is in any popular format like avi,mp4 ,flv,3gp,ogg ,mp3,mov etc. you can set height, width and other attrib.
  Permalink  
Comments
Manas Bhardwaj at 8-Jun-12 15:17pm
   
Correct!
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

  Permalink  
Comments
Manas Bhardwaj at 8-Jun-12 15:18pm
   
+5 for links!
Sandeep Mewara at 9-Jun-12 0:57am
   
Thanks.
thatraja at 9-Jun-12 3:20am
   
5!
Sandeep Mewara at 9-Jun-12 6:41am
   
Thanks Raja.
SoMad at 9-Jun-12 17:49pm
   
I agree, great links. +5.
 
Soren Madsen
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 3

Let me Google that for you.[^]
 
Google is free. Use it as much as you can. 99 out of 100 times, you will find answer on your own. It saves so much time and if you still have issues, please come back and someone should be able to help you.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 4

Dear Friend,
 
You can use HTML5
<video> Tag
 
<video width="500" height="300" controls="controls">
  <source src="movie.mp4" type="video/mp4" />
</video>
 
But the browser you use, should support HTML5.
 
Regards,
AP
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 277
1 Maciej Los 240
2 DamithSL 200
3 Raul Iloc 185
4 Richard MacCutchan 175
0 OriginalGriff 5,130
1 DamithSL 4,197
2 Maciej Los 3,670
3 Kornfeld Eliyahu Peter 3,470
4 Sergey Alexandrovich Kryukov 2,821


Advertise | Privacy | Mobile
Web04 | 2.8.141216.1 | Last Updated 9 Jun 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100