473,387 Members | 1,517 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,387 software developers and data experts.

Access an embed object via javascript

Hi,

I want to access the features of a plugin without actually embedding
it into a page. Is this possible?

Eg

The code to embed the object into a page is:

<OBJECT classid='CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5
codebase='http://www.test.com/plug.cab#version=3,1' "id='myPlugin'
height='0' width='0'>

<EMBED type='application/x-myPlugin' name='myPlugin' hidden='true'
src='in.txt'></EMBED>

</OBJECT>

I could simply add this using document.write, but for various reasons
I dont want to do this.
I would rather do something like:

var plugin = (navigator.mimeTypes &&
navigator.mimeTypes["application/x-Web-Plugin"]) ?
navigator.mimeTypes["application/x-Web-Plugin"].enabledPlugin : 0;

myObj = new object("CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5");

myObj.pluginMethod

Thanks
Jul 23 '05 #1
2 1896


Phil wrote:

I want to access the features of a plugin without actually embedding
it into a page. Is this possible?

Eg

The code to embed the object into a page is:

<OBJECT classid='CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5
codebase='http://www.test.com/plug.cab#version=3,1' "id='myPlugin'
height='0' width='0'>

<EMBED type='application/x-myPlugin' name='myPlugin' hidden='true'
src='in.txt'></EMBED>

</OBJECT>

I could simply add this using document.write, but for various reasons
I dont want to do this.
I would rather do something like:

var plugin = (navigator.mimeTypes &&
navigator.mimeTypes["application/x-Web-Plugin"]) ?
navigator.mimeTypes["application/x-Web-Plugin"].enabledPlugin : 0;

myObj = new object("CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5");

myObj.pluginMethod


With MSIE/Win you might be able to use
var control = new ActiveXObject('program.id')
and then script that but you need to find out the program id of that
CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5.

--

Martin Honnen
http://JavaScript.FAQTs.com/
Jul 23 '05 #2
Martin Honnen <ma*******@yahoo.de> wrote in message news:<41***********************@newsread4.arcor-online.net>...
Phil wrote:

I want to access the features of a plugin without actually embedding
it into a page. Is this possible?

Eg

The code to embed the object into a page is:

<OBJECT classid='CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5
codebase='http://www.test.com/plug.cab#version=3,1' "id='myPlugin'
height='0' width='0'>

<EMBED type='application/x-myPlugin' name='myPlugin' hidden='true'
src='in.txt'></EMBED>

</OBJECT>

I could simply add this using document.write, but for various reasons
I dont want to do this.
I would rather do something like:

var plugin = (navigator.mimeTypes &&
navigator.mimeTypes["application/x-Web-Plugin"]) ?
navigator.mimeTypes["application/x-Web-Plugin"].enabledPlugin : 0;

myObj = new object("CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5");

myObj.pluginMethod


With MSIE/Win you might be able to use
var control = new ActiveXObject('program.id')
and then script that but you need to find out the program id of that
CLSID:7FA62735-AHC3-14d2-9F81-00114B3245C5.


Thats something like what im looking for, the only problem is that
this has to work in Mozilla Firefox ( and not IE!).

Thanks
Jul 23 '05 #3

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

Similar topics

3
by: Tony Sutton | last post by:
I have this following code in my html file: <object classid="clsid:166B1BCA-3F9C-11CF-8075-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/director/sw.cab#...
2
by: chaitatp | last post by:
Hi guys, I have posted a similar question before but this post has some different. The similar link is: ...
8
by: Jerry | last post by:
I have an off-the-shelf app that uses an Access database as its backend. One of the tables contains a field with an "OLE Object" datatype. I'm writing some reports against this database, and I...
5
by: Mark Broadbent | last post by:
Does anybody know of any good url references that give good examples of accessing .net dlls or exes through Javascript. I cannot do this through aspx or asp pages but only client side .html code. ...
3
by: abrtlt | last post by:
I would like to have a web page in which, when the user clicks on any of several specific elements, a specific audio file is played, without reloading the page. The specific audio file name is...
3
by: Anil Gupte | last post by:
I want to embed using an embed tag or object tag (like YouTube or others do) to embed a video file in a web page. I want to know if there is an event related to the video being done playing. Also...
5
by: elbin | last post by:
Hello, first to say that I am a total beginner in Javascript but I know some programming (python in particular) and am able to understand methods/parameters and so on. Here's my problem: I am...
1
by: ShahzadMahmood | last post by:
I want to embed the following code in javascript function javascript function is written just after the object code, I want to replace the popup window code with this object code while the file name...
2
dream party
by: dream party | last post by:
Inserting a Flash (SWF, FLV) file into HTML web page is already an old and familiar thing to all of us. It is a rather non-flexible thing that just to edit some options in the template. However, I...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
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:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

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.