Hi,
Please tell me the best approach and source code to embed a avi and wmv video in my website using PHP or javascript.
Regards,
Sobha
embed video in website
Moderator: General Moderators
Re: embed video in website
you have to convert .avi and .wmv video into flv format.(you can convert it through FFMpeg).
Then you can play those videoa through any flash vido player.
Then you can play those videoa through any flash vido player.
Re: embed video in website
Thanks for your reply.I converted my files to .flv format and tried the following code .But it is not working.Please help.
Regards,
Sobha
Code: Select all
<html><head><script type="text/javascript" src="swfobject.js"></script></head><body>
<p id="player"><a href="http://www.macromedia.com/go/getflashplayer">Get Flash</a> to see this player.</p>
<script type="text/javascript">
var so = new SWFObject('mediaplayer.swf','player','280','230','7');
so.addParam("allowfullscreen","true");
so.addVariable("file","LuanaNodaVideo.flv");
so.addVariable("height","230");
so.addVariable("width","280");
so.write('player');
</script></body>
</html>
Sobha
- Attachments
-
- swfobject.rar
- (29.25 KiB) Downloaded 12 times
Last edited by Benjamin on Thu Jul 16, 2009 7:55 pm, edited 1 time in total.
Reason: Added [code=html] tags.
Reason: Added [code=html] tags.
Re: embed video in website
is your falsh video player working good..? one more thing i noticed that your video1.html still use "LuanaNodaVideo.wmv" not "LuanaNodaVideo.flv".Also, that video file is not available in the folder.
in my system it does not show the flash player.. i tried with AC_RunActiveContent.js, please see video2.html in attachment.
i used my own video, player is comming in browser. but it is not playing the video. i hope there might be problem with your player please double check that.
in my system it does not show the flash player.. i tried with AC_RunActiveContent.js, please see video2.html in attachment.
i used my own video, player is comming in browser. but it is not playing the video. i hope there might be problem with your player please double check that.
- Attachments
-
- swfobject.rar
- (32.31 KiB) Downloaded 13 times
Re: embed video in website
Thanks for your reply.As you told player is comming in browser. but it is not playing the video.Is it due to problem in mediaplayer.swf file.Do you have any other working codes?
Re: embed video in website
yes it might be problem with mediaplayer.swf. are you sure with a input parameters to the player. are you sure "file" is parameter name? if that is correct, then problem with your player. try to use any other player(.swf) to play the video.
Re: embed video in website
Hi,
Thanks for your reply.I made a slight modification in my code.Please check the video.html file in the attachment.Now this coding is working in my system .But it is not playing in the production system.Do i need to have any settings to be done in the server?
Regards,
Sobha
Thanks for your reply.I made a slight modification in my code.Please check the video.html file in the attachment.Now this coding is working in my system .But it is not playing in the production system.Do i need to have any settings to be done in the server?
Regards,
Sobha
- Attachments
-
- video.rar
- (241.58 KiB) Downloaded 6 times
Re: embed video in website
it is playing good in my system.. i hope that video.flv file might not uploaded properly in server.
check the file existence and file size in the server.
check the file existence and file size in the server.
Re: embed video in website
Hi,
Thanks for your reply.That file is playing properly in server also when i directly double click that video.html file.But not playing when run through http://localhost/video/video.html.
The image and player is displayed.But the video is not playing.Is it something related to IIS?
please help.
Regards,
Sobha
Thanks for your reply.That file is playing properly in server also when i directly double click that video.html file.But not playing when run through http://localhost/video/video.html.
The image and player is displayed.But the video is not playing.Is it something related to IIS?
please help.
Regards,
Sobha