Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > Determining if ActiveX Controls are Disabled

Reply
Thread Tools

Determining if ActiveX Controls are Disabled

 
 
DartmanX
Guest
Posts: n/a
 
      10-12-2005
Is there a simple way to determine if someone using Internet Explorer
has completely disabled ActiveX controls?

Jason

 
Reply With Quote
 
 
 
 
cwdjrxyz@yahoo.com
Guest
Posts: n/a
 
      10-13-2005

DartmanX wrote:
> Is there a simple way to determine if someone using Internet Explorer
> has completely disabled ActiveX controls?
>
> Jason


Perhaps someone else knows of a simple way to detect if ActiveX is
disabled. It is true that IE browsers and close relatives such as MSN9,
MyIE2, and Avant can handle general ActiveX, if not disabled. However
several other browsers can use plugins to handle a very limited subset
of ActiveX(there are some hacks for general ActiveX on many browsers
which I would not use). For example recent Netscape browsers came with
ActiveX support for the WMP only. Also there are plugins that can be
downloaded for the same type of ActiveX support of the WMP for Mozilla
and Firefox. This should be kept in mind in any test designed to detect
full or partial ActiveX support.

Media pages often use ActiveX. In this case the standard way seems to
be to write a dual path for browsers that do and do not support ActiveX
rather than detecting ActiveX support. For example one can write an
ActiveX object for the WMP that allows many control parameters. One can
also include a second ordinary object(or embed if one does not care
about standards)that usually allows fewer controls. If the browsers
does not support ActiveX, the second path is automatically taken. That
is just the way an ActiveX object is designed to work. I have often
seen such an approach used for Real media and flash as well as for
Microsoft wmv and wma formats. ActiveX objects are very easy to spot.
They have a 32 digit hex ID that is unique for each device or program
to be controlled.

 
Reply With Quote
 
 
 
 
DartmanX
Guest
Posts: n/a
 
      10-13-2005
Well, the reason I ask the question is because what I am doing needs to
be able to determine if ActiveX is completely disabled on IE in order
to display a "Sorry, this function won't work" message.

Jason

 
Reply With Quote
 
Richard Cornford
Guest
Posts: n/a
 
      10-13-2005
DartmanX wrote:
> Is there a simple way to determine if someone using Internet
> Explorer has completely disabled ActiveX controls?


Ask them?

Richard.


 
Reply With Quote
 
cwdjrxyz@yahoo.com
Guest
Posts: n/a
 
      10-13-2005

DartmanX wrote:
> Well, the reason I ask the question is because what I am doing needs to
> be able to determine if ActiveX is completely disabled on IE in order
> to display a "Sorry, this function won't work" message.
>
> Jason


I do not think that javascript is a good answer. Even if you can come
up with a script that can detect ActiveX support or not with 100%
accuracy, there is a problem. Many people who turn off ActiveX also
turn off javascript. For all such people, a script method is doomed to
failure. Thus, if the detection you wish is reasonable at all, it
likely needs to be done on the server using php script, Perl, or
something of the sort.

 
Reply With Quote
 
Randy Webb
Guest
Posts: n/a
 
      10-13-2005
http://www.velocityreviews.com/forums/(E-Mail Removed) said the following on 10/12/2005 10:56 PM:

> DartmanX wrote:
>
>>Well, the reason I ask the question is because what I am doing needs to
>>be able to determine if ActiveX is completely disabled on IE in order
>>to display a "Sorry, this function won't work" message.
>>
>>Jason

>
>
> I do not think that javascript is a good answer. Even if you can come
> up with a script that can detect ActiveX support or not with 100%
> accuracy, there is a problem. Many people who turn off ActiveX also
> turn off javascript.


I have JS enabled, ActiveX disabled. I understand how my browser works,
how ActiveX works, and what kind of security holes I am opening/closing
by having it set that way.

> For all such people, a script method is doomed to failure.


That is not true. JS/ActiveX is the best answer to answer a JS/ActiveX
question. You put the warning in the page and then have JS/ActiveX
remove it.

"Warning: I have no idea how to implement my page without JS and ActiveX
so if you see this then I failed in my objective of producing an
accessible webpage to all."

Then, you write an ActiveX object that would change that text. Pretty
simple stuff.

If the warning stays, then JS is disabled and the user is notified. If
JS/ActiveX is available, it removes the warning and JS/ActiveX enabled
users get the enhancement.

> Thus, if the detection you wish is reasonable at all, it
> likely needs to be done on the server using php script, Perl, or
> something of the sort.


Huh? And how would the server attempt to determine that? It can't
possible determine it better than JS could attempt to determine it.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
 
Reply With Quote
 
cwdjrxyz@yahoo.com
Guest
Posts: n/a
 
      10-13-2005

Randy Webb wrote:
> (E-Mail Removed) said the following on 10/12/2005 10:56 PM:
>
> > DartmanX wrote:
> >
> >>Well, the reason I ask the question is because what I am doing needs to
> >>be able to determine if ActiveX is completely disabled on IE in order
> >>to display a "Sorry, this function won't work" message.
> >>
> >>Jason

> >
> >
> > I do not think that javascript is a good answer. Even if you can come
> > up with a script that can detect ActiveX support or not with 100%
> > accuracy, there is a problem. Many people who turn off ActiveX also
> > turn off javascript.

>
> I have JS enabled, ActiveX disabled. I understand how my browser works,
> how ActiveX works, and what kind of security holes I am opening/closing
> by having it set that way.



>
> > For all such people, a script method is doomed to failure.

>
> That is not true. JS/ActiveX is the best answer to answer a JS/ActiveX
> question. You put the warning in the page and then have JS/ActiveX
> remove it.
>
> "Warning: I have no idea how to implement my page without JS and ActiveX
> so if you see this then I failed in my objective of producing an
> accessible webpage to all."
>
> Then, you write an ActiveX object that would change that text. Pretty
> simple stuff.
>
> If the warning stays, then JS is disabled and the user is notified. If
> JS/ActiveX is available, it removes the warning and JS/ActiveX enabled
> users get the enhancement.
>
> > Thus, if the detection you wish is reasonable at all, it
> > likely needs to be done on the server using php script, Perl, or
> > something of the sort.

>
> Huh? And how would the server attempt to determine that? It can't
> possible determine it better than JS could attempt to determine it.
>
> --
> Randy
> comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly


You do not need to use script at all in many cases - you just take
advantage of the AX object. As I mentioned in my first post, if you
use an AX object and AX is not supported, a second path will be taken
if it is included in the AX object. This second path can be a simple
paragraph that states anything you wish. See
http://www.cwdjr.info/souearly/AXtest.php . This includes an AX object
for the WMP with no other player path if AX is not installed or turned
off. Instead the second path is just a paragraph. Of course you must
have a WMP installed to view how the player works. If I view the page
on IE6 with ActiveX on, the player works. It also works on my Firefox
browser for which I have downloaded the AX plugin for the WMP only. The
player does not appear on my Mozilla, because I have not installed an
AX plugin for the WMP on it. Instead you get the warning that AX is not
installed or turned off. The same happens for the old Netscape 4.8 and
Amaya, which has no AX or javascript installed. The most recent Opera
is a special case. It plays the page as if it had AX installed. I
believe that Opera is using some trick to play media written with AX
support only, even though I doubt if Opera supports AX directly. I wish
someone from Opera would tell us exactly what is going on.

 
Reply With Quote
 
Randy Webb
Guest
Posts: n/a
 
      10-13-2005
(E-Mail Removed) said the following on 10/13/2005 12:30 AM:

<snip>
>
>
> You do not need to use script at all in many cases - you just take
> advantage of the AX object.


Huh? The post I quoted you say this:

<quote>
Thus, if the detection you wish is reasonable at all, it
likely needs to be done on the server using php script, Perl, or
something of the sort.
</quote>

And now you say to use AX to detect AX? (which is exactly what I said).

> As I mentioned in my first post, if you use an AX object and AX is
> not supported, a second path will be taken if it is included in the AX
> object. This second path can be a simple paragraph that states anything
> you wish.


Which is the same effect as I described.

AX itself determines whether it is available or not - not the server.

The server is very rarely (if ever) the best place to try to determine
if a client side technology is available or not.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
 
Reply With Quote
 
cwdjrxyz@yahoo.com
Guest
Posts: n/a
 
      10-13-2005

Randy Webb wrote:
> (E-Mail Removed) said the following on 10/13/2005 12:30 AM:
>
> <snip>
> >
> >
> > You do not need to use script at all in many cases - you just take
> > advantage of the AX object.

>
> Huh? The post I quoted you say this:
>
> <quote>
> Thus, if the detection you wish is reasonable at all, it
> likely needs to be done on the server using php script, Perl, or
> something of the sort.
> </quote>
>
> And now you say to use AX to detect AX? (which is exactly what I said).
>
> > As I mentioned in my first post, if you use an AX object and AX is
> > not supported, a second path will be taken if it is included in the AX
> > object. This second path can be a simple paragraph that states anything
> > you wish.

>
> Which is the same effect as I described.
>
> AX itself determines whether it is available or not - not the server.
>
> The server is very rarely (if ever) the best place to try to determine
> if a client side technology is available or not.
>
> --
> Randy
> comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly


Perhaps you did not see my first post or it has not appeared on your
newsreader yet, so I will quote the part about a second path that I
mentioned there.

"Media pages often use ActiveX. In this case the standard way seems to
be to write a dual path for browsers that do and do not support ActiveX
rather than detecting ActiveX support. For example one can write an
ActiveX object for the WMP that allows many control parameters. One can
also include a second ordinary object(or embed if one does not care
about standards)that usually allows fewer controls. If the browsers
does not support ActiveX, the second path is automatically taken. That
is just the way an ActiveX object is designed to work."

I just detailed this and gave a working example for a paragraph as a
second path on the post you quoted. Of course if you view many pages
with AX objects, you will find all sorts of html used as a second path
if AX is not installed or turned off, so this is nothing new at all.

In case anyone wonders, the php include in the example page has nothing
to do with the AX object. It just writes and serves the page as proper
xhtml 1.1 served as application/xhtml+hml for browsers that will accept
this mime type. For outmoded browsers, such as the IE6, that will not
accept this mime type, the page is rewritten as html 4.01 strict, and a
comment is added to the source code telling what was done. You can see
this by viewing on the IE6 and checking the source code.

For the record, there are, or were, very complicated scripts for
detecting if a WMP, for example, is installed, what version it is, and
if there is AX support for it. This is/was somewhere on the vast
Microsoft sites. The best I remember, it used 2 javascripts(or perhap
Microsoft Jscripts?) and 1 vb script. Because of the vb script, this
method would not work on many other non-Microsoft browsers.

 
Reply With Quote
 
The Magpie
Guest
Posts: n/a
 
      10-14-2005
Richard Cornford wrote:
> DartmanX wrote:
>
>>Is there a simple way to determine if someone using Internet
>>Explorer has completely disabled ActiveX controls?

>
> Ask them?
>

Even if it is enabled, Javascript is a silly way to try and find out.
What if Javascript is disabled?
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
ActiveX control in python vs ActiveX control in vb 6 (piece of code) vml Python 0 08-22-2007 09:57 AM
Determining the exact location and current state of any controls Peter Olcott Javascript 10 08-15-2006 07:06 PM
ActiveX apologetic Larry Seltzer... "Sun paid for malicious ActiveX code, and Firefox is bad, bad bad baad. please use ActiveX, it's secure and nice!" (ok, the last part is irony on my part) fernando.cassia@gmail.com Java 0 04-16-2005 10:05 PM
TextBox controls determining if text is highlighted or selected studen771 ASP .Net Web Controls 3 03-31-2005 06:19 PM
validator controls and disabled controls =?Utf-8?B?RHVuZQ==?= ASP .Net 2 02-04-2004 08:27 PM



Advertisments