简体   繁体   中英

VLC ActivX plugin not playing video in update IE9

I am using vlc ActiveX plugin on web browser IE9 to play video live streaming.

Its work perfect in IE8 but when I update browser from IE8 to IE9 than it not playing video file or live straming.

here is my code.

<object type="application/x-vlc-plugin" id="vlc" width="517" height="388" classid="clsid:9BE31822-FDAD-461B-AD51-BE1D1C159921">
                    <param name="MRL" id="mrlVideo" value="" />
                    <param name="volume" value="50" />
                    <param name="autoplay" value="True" />
                    <param name="loop" value="false" />
                    <param name="fullscreen" value="false" />
                    <param name="wmode" value="transparent" />
                    <param name="toolbar" value="true" />
                    <param name="windowless" value="true" />
                </object>

and in javascript I am using these

 var vlc = document.getElementById("vlc");
        var options = new Array(":rtsp-tcp"); 
        var urlVideofile = "hppt://IP:portnumber/"
        var id = vlc.playlist.add(urlVideofile, null, options);
        vlc.playlist.playItem(id);

Here is attach image that showing what exactly error is coming

在此处输入图片说明

Any help is greatly appreciated

Thanks.

JavaScript is case-sensitive. You need to access vlc.playlist (not vlc.Playlist ), call vlc.playlist.add (not vlc.Playlist.Add ) and vlc.playlist.play (not vlc.playlist.Play ). IE9's JavaScript engine is more standards-compliant than previous versions of IE, which may have allowed case-insensitive access to ActiveX/COM APIs .

Additionally, a bug was introduced in VLC 2.0.6 that breaks the ActiveX API, so you will need to use VLC 2.0.5 or earlier. (Despite what is stated in #8627, this issue is not fixed in VLC 2.0.7, which appears to still include the 2.0.6 ActiveX plugin for some reason.)

We have found the solutions as

//var options = [":rtsp-tcp"]; //commented out

//replace the line above with this.Note the CSA key is pre-pended with:
var options = [":ts-csa-ck="+EncryptionkeyValue]; 

//options.push("ts-csa-ck=EncryptionkeyValue");  //commented out as its above now
var itemId = vlc.playlist.add(targetURL, "", options); // continue as normal
var id = vlc.playlist.add(urlVideofile, null, options);
vlc.playlist.playItem(id);

Its working fine for Browsers including IE8 which have highest version, IE9, IE10 , Chrome, and FF.

Thanks

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM