|
|
| (8 intermediate revisions by 3 users not shown) |
| Line 1: |
Line 1: |
| == VLCjs javascript library ==
| | #redirect[[Documentation:WebPlugin]] |
| | |
| I've created this small javascript library to allows you to easyly add the VLC plugin in your web pages.
| |
| | |
| Here's how you add the control to your page :
| |
| | |
| * first, download the [http://code.revolunet.com/VLCjs/VLSjs.zip source zip] and extract it to your website (i suppose you create a VLCjs subfolder)
| |
| * then, create a simple html test page like this on your server :
| |
| <script language="javascript" src="VLCjs/VLCjs.js"></script>
| |
| <object id="myplayer" classid="clsid:9BE31822-FDAD-461B-AD51-BE1D1C159921" codebase="http://downloads.videolan.org/pub/videolan/vlc/latest/win32/axvlc.cab"></object>
| |
| <script language="javascript">
| |
| window.onload = function() {
| |
| var vlc = new VLCplayer("myplayer", 400, 300);
| |
| vlc.setIdleImage("idle2.gif");
| |
| vlc.play("http://example.com/movie.mpeg");
| |
| }
| |
| </script>
| |
| | |
| this should create a player object and launch a movie ;)
| |
| | |
| * You can find a demo here : http://vlc.revolunet.com (some demo medias specially for french free.fr users)
| |
| * check out the docs here : http://code.revolunet.com/VLCjs/EN
| |
| | |
| Any comments are welcome to improve this lib !!
| |
| | |
| It works on IE/Firefox and maybe Safari but i cannot test it
| |