Page 1 of 1

How to play video on the web.

Posted: 15 Apr 2009 06:38
by jsmkbunch2000
Hello. I am a noob. I don't know any code or http scripting. I figured out how to run the VlC on one computer and stream it to another computer on VLC (as client) using UDP foramt. I found the following code in searching the forums to create a player in my web browser, saved as html doc. (see posting here: viewtopic.php?f=16&t=57636&p=194069#p194069 ) My browser shows it is waiting for video now, so how to I stream a video to my web browser. I am using firefox on Windows XP Os. Please provide step by step instrux on what to do next to play on my web browser. Thanks

Code: Select all

<embed type="application/x-vlc-plugin" width="800" height="600" autoplay="no" loop="no" id="vlc"></embed> <script type="text/javascript"> function timer(){ mediatimer = setTimeout("timer()", 500) if (vlc.playlist.isPlaying == false) { //set and play video vlc.playlist.add("videofolder/" + source_playlist[current_media]['content'], "", options); vlc.playlist.add("vlc://quit"); vlc.playlist.play(); current_video+=1; } if (current_video == source_playlist.length) { current_video = 0; } } var options = new Array(":audio", ":quiet-synchro", ":no-video-title-show"); var vlc = document.getElementById("vlc"); //setup playlist array - can be sourced from file source_playlist = new Array(); source_playlist[0] = new Array(); source_playlist[0]['content'] = "video1.avi"; source_playlist[1] = new Array(); source_playlist[1]['content'] = "video2.avi"; var current_media = 0; timer(); </script>