ActiveX/HTML: Difference between revisions

From VideoLAN Wiki
Jump to navigation Jump to search
Tonsofpcs (talk | contribs)
moved out of ActiveX
 
Hogi (talk | contribs)
No edit summary
Line 16: Line 16:
   document.vlc.addTarget("...",options,2,0); // replace entry 0
   document.vlc.addTarget("...",options,2,0); // replace entry 0
   document.vlc.play();
   document.vlc.play();
==See also==
*[[ActiveX/Delphi|Delphi Implementation]]
* [[ActiveX|ActiveX Description]]

Revision as of 10:26, 6 March 2006

You can insert the ActiveX control in your HTML pages like this :

 <OBJECT classid="clsid:E23FE9C6-778E-49D4-B537-38FCDE4887D8"
    codebase="http://downloads.videolan.org/pub/videolan/vlc/latest/win32/axvlc.cab"
       width="640" height="480" id="vlc" events="True">
 <param name="Src" value="" />
 <param name="ShowDisplay" value="True" />
 <param name="AutoLoop" value="False" />
 <param name="AutoPlay" value="False" />
 </OBJECT>

Then, using Javascript, you can select another source, or change the audio track :

 document.vlc.playlistClear();
 var options=[":audio-track=5"]; // select audio track 5 (=6th, 1st is 0)
 document.vlc.addTarget("...",options,2,0); // replace entry 0
 document.vlc.play();

See also