Cannot embed VLC within HTML page
Posted: 23 Dec 2010 21:27
Dear experts,
Iam a newbie in VLC.
I try to create an HTML page that will embed the VLC player and play TV channels within the browser.
I use Mozilla 3.5.3 and I have installed the VLC plugin 1.0.2.
I have followed the instructions mentioned at http://wiki.videolan.org/Documentation:WebPlugin
This is my HTML code (actually it is the outcome of a Java Server Faces page):
<html>
<head>
<meta http-equiv="Content-Type"
content="text/html; charset=windows-1253"/>
<script type="text/javascript" language="javascript">
function playVlc(){
var vlc = document.getElementById("vlc");
if (vlc.video == null)
alert('No video object found');
else{
alert ('Video object found');
vlc.video.fullscreen = true;
vlc.playlist.play();
}
}
</script>
<title>ViewTv</title>
</head>
<body><form id="form1" name="form1" style="margin:0px" onkeypress="return _submitOnEnter(event,'form1');" method="POST" action="/Hera-GUI-context-root/faces/patient/ViewTv.jsp">
<embed type="application/x-vlc-plugin"
pluginspage="http://www.videolan.org"
version="VideoLAN.VLCPlugin.2" width="640" height="480"
id="vlc"></embed>
<input id="form1:commandButton1" name="form1:commandButton1" type="submit" value="commandButton1" onclick="return _chain('playVlc()','submitForm(\'form1\',1,{source:\'form1:commandButton1\'});return false;',this,event,true)">
<input type="hidden" name="oracle.adf.faces.FORM" value="form1"><span id="_form1_Postscript"><input type="hidden" name="oracle.adf.faces.STATE_TOKEN" value="-4x9qoa5mh"><script>function _form1Validator(){return true;}var form1_SF={};</script></span><script>_submitFormCheck();</script></form></body>
</html>
When the Javascript code is executed, the alert box that the vlc.video object is null is displayed. So I deduce that the browser cannot access the VLC plugin.
The same behaviour appears for the Firefox and Internet Explorer
Can anybody identify where the problem might be ?
Iam a newbie in VLC.
I try to create an HTML page that will embed the VLC player and play TV channels within the browser.
I use Mozilla 3.5.3 and I have installed the VLC plugin 1.0.2.
I have followed the instructions mentioned at http://wiki.videolan.org/Documentation:WebPlugin
This is my HTML code (actually it is the outcome of a Java Server Faces page):
<html>
<head>
<meta http-equiv="Content-Type"
content="text/html; charset=windows-1253"/>
<script type="text/javascript" language="javascript">
function playVlc(){
var vlc = document.getElementById("vlc");
if (vlc.video == null)
alert('No video object found');
else{
alert ('Video object found');
vlc.video.fullscreen = true;
vlc.playlist.play();
}
}
</script>
<title>ViewTv</title>
</head>
<body><form id="form1" name="form1" style="margin:0px" onkeypress="return _submitOnEnter(event,'form1');" method="POST" action="/Hera-GUI-context-root/faces/patient/ViewTv.jsp">
<embed type="application/x-vlc-plugin"
pluginspage="http://www.videolan.org"
version="VideoLAN.VLCPlugin.2" width="640" height="480"
id="vlc"></embed>
<input id="form1:commandButton1" name="form1:commandButton1" type="submit" value="commandButton1" onclick="return _chain('playVlc()','submitForm(\'form1\',1,{source:\'form1:commandButton1\'});return false;',this,event,true)">
<input type="hidden" name="oracle.adf.faces.FORM" value="form1"><span id="_form1_Postscript"><input type="hidden" name="oracle.adf.faces.STATE_TOKEN" value="-4x9qoa5mh"><script>function _form1Validator(){return true;}var form1_SF={};</script></span><script>_submitFormCheck();</script></form></body>
</html>
When the Javascript code is executed, the alert box that the vlc.video object is null is displayed. So I deduce that the browser cannot access the VLC plugin.
The same behaviour appears for the Firefox and Internet Explorer
Can anybody identify where the problem might be ?