473,402 Members | 2,061 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,402 software developers and data experts.

IE error when trying to use plugin methods

I am trying to use the methods in quicktimes plugin, but IE generetes
an error. I have tried to use the "document.all" instead of
getElementById but the results remain the same. It won't recognise
"movie1" and "movie2" as objects, and it won't allow me to use their
methods.

And of course IE generates an error message that says nothing about
what might be wrong.

Another problem with this code is that I cannot get the lenght of the
movie because it is streamed with rtsp. Any suggestions?

Here is my code:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="content-type" content="text/html;charset=iso-8859-1"
/>
<script language=JavaScript" type="text/javascript">

var movieEnd;
var movieNow;

</script>

<style type="text/css">
<!--

#movie1 {
position:absolute;
top:20px;
left:20px;
visibility:hidden;
}
#movie2 {
position:absolute;
top:20px;
left:20px;
visibility:visible;
}

-->

</style>
</head>
<body>
<form1><OBJECT
classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B"
codebase="http://www.apple.com/qtactivex/qtplugin.cab"
width="320" height="256" id="movie2"
<PARAM name="src" value="L1M1.mov">
<PARAM name="autostart" value="false">

<EMBED HEIGHT=256 WIDTH=320
SRC="L1M1.mov"

TYPE="video/quicktime"
PLUGINSPAGE="www.apple.com/quicktime/download"

NAME="movie2" autostart="false">
<EMBED />
</OBJECT>

<OBJECT
classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B"
codebase="http://www.apple.com/qtactivex/qtplugin.cab"
width="320" height="256" id="movie1" >
<PARAM name="src" value="L1M1.mov">
<PARAM name="autostart" value="false">
<EMBED HEIGHT=256 WIDTH=320
SRC="L1M1.mov"
TYPE="video/quicktime"
PLUGINSPAGE="www.apple.com/quicktime/download"

NAME="movie1" autostart="false">
<EMBED />
</OBJECT>
</form1>

<script language=JavaScript" type="text/javascript">
<!--

function changeVisibility(id,action) {
var objId = id;
switch (action) {
case "show":
document.form1.getElementById(''+id+'').style.visi bility.toLowerCase()
= "visible";}
case "hide":
document.form1.getElementById(''+id+'').style.visi bility.toLowerCase()
= "hidden";

default:return;
}
return;

}
function changePosition(id,x,y) {
document.form1.getElementById(ObjId).style.left = x+"px";
document.form1.getElementById(ObjId).style.top = y+"px";
}

/* define function that calls QuickTime's "Play" method */
function PlayIt(id)
{
if (id=="movie1") {
document.form1.movie1.Play();
} else if (id=="movie2") {
document.form1.movie2.Play();
}

}

/* define function that calls QuickTime's "Stop" method */
function StopIt(anObj)
{
if (id=="movie1") {
document.form1.movie1.Stop();
} else if (id=="movie2") {
document.form1.movie2.Stop();
}

}
function changeIfEnd(id) {
if (id=="movie1") {
while (document.form1.movie1.GetPluginStatus() == "Loading") {}

var movieEnd =document.form1.movie2.GetEndTime();
var movieNow =document.form1.movie2.GetTime();
} else if (id=="movie2") {

while (document.fomr1.movie2.GetPluginStatus() == "Loading") {}
var movieEnd =document.form1.movie2.GetEndTime();
var movieNow =document.form1.movie2.GetTime();
}

timeUntilSwitch = setTimeout("switchMovie()",(movieEnd-movieNow);

}

function switchMovie() {
PlayIt('movie1');
for (var i = 1; i <= 10000; i++) {}
changeVisibility('movie1','show');
changeVisibility('movie2','hide');

}

//-->
</script>

<P style="position:absolute;
top:400px;
left:200px;">
<br> <a href="javascript:PlayIt('movie2');" onclick="changeIfEnd('movie2');"PlayIt</a><br>

<a href="javascript:StopIt('movie2');">StopIt</a><br>
</P>

</body>
</html>

Oct 13 '05 #1
1 1388
> "torbs" <to********@gmail.com> wrote:
news:11**********************@f14g2000cwb.googlegr oups.com....

I am trying to use the methods in quicktimes plugin, but IE generetes
an error. I have tried to use the "document.all" instead of
getElementById but the results remain the same. It won't recognise
"movie1" and "movie2" as objects, and it won't allow me to use their
methods.

And of course IE generates an error message that says nothing about
what might be wrong.
Another problem with this code is that I cannot get the lenght of the
movie because it is streamed with rtsp. Any suggestions?

Here is my code:
<snip>


line 7 column 1 - Warning: <script> unexpected or duplicate quote mark
line 37 column 1 - Warning: inserting missing 'title' element
line 41 column 1 - Error: <form1> is not recognized!
line 41 column 1 - Warning: discarding unexpected <form1>
line 41 column 8 - Error: <object> missing '>' for end of tag
line 72 column 1 - Warning: discarding unexpected </form1>
line 76 column 2 - Warning: <script> unexpected or duplicate quote mark

Error: syntax error Line: 85
Source Code: case "hide":
Expected '}'

See if any of this info helps

--
BootNic Thursday, October 13, 2005 12:47 PM

Our earth is degenerate in these latter days; bribery and corruption are common; children no longer
obey their parents; and the end of the world is evidently approaching.
*Assyrian clay tablet 2800 B.C.*
Oct 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

9
by: torbs | last post by:
Hi I am creating a page for stretchfilm. In this page you can chose between a short medium and long version of the film at any point in the film. It is in norwegian, but just press play. URL:...
0
by: philipp | last post by:
I have the following problem: My client application (c#, WindowsForms) uses the IE Browser ActiveX Control to display either HTML or PDF files. This is fine so far. If the Acrobat Reader is...
0
by: Vasco Lohrenscheit | last post by:
Hello, in the following situation the wrong virtual method gets called: ----------------------------------------------------- //assembly1 #include "../Plugin/iPlugin.h" //ISO c++ type iPlugin...
8
by: Razak | last post by:
Hi, I have a class which basically do Impersonation in my web application. From MS KB sample:- ++++++++++++++++++++code starts Dim impersonationContext As...
2
by: Edvard Majakari | last post by:
Hi, My idea is to create a system working as follows: each module knows path to plugin directory, and that directory contains modules which may add hooks to some points in the code. Inspired...
4
by: Gary | last post by:
Hi, I get this error " " when my web page run, what does it mean? Hope someone can help!!! Gary
6
by: S. Lorétan | last post by:
Hi guys. I am preparing the rewriting of an huge existing application in VB6. This software is a mess of 10 years of patchs and new functionalities added randomly, and didn't have any logical or...
0
by: Vids | last post by:
Hi, We are doing migration of web service from VS2003 to VS2005 After upgrading the project I m trying to add a web reference to the web service. While adding web reference it shows all the web...
2
by: cloudy | last post by:
First at all, i'm sorry, i not good in writing english. i want to retrieve a string from my applet via Javascript. I use a method named ReadAll. public String ReadAll(String StrOut, String...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.