PDA

View Full Version : Activating ActiveX Controls Work around



Bit0Byte
11-15-2006, 07:15 AM
As a web designer I use flash and have clients that insist on flash sites. However, Internet Explorer now requires permission to active the site. Is there a simple work around or coding I can use to avoid having the viewer having to activate the site.

I have tried the http://www.amarasoftware.com/flash-problem.htm without sucess, and the MS solution (http://msdn.microsoft.com/library/default.asp?url=/workshop/author/dhtml/overview/activating_activex.asp) is beyond my skill level/patience.

Thanks

wildjokerdesign
11-15-2006, 07:49 AM
What is the problem you had with the Amara solution? It seems pretty straight forward and easy to implement. I do see that with both the easy solution and with Macromedias that if a user has javascript turned off (not unheard of) that the flash file would still not play. I guess to combat that you could add this code to your page:

<noscript>A message to the user that they need to either activate the flash file or javascript to use site.</noscript>In theory that would show up only if they had javascript turned off and would let them know they needed to do something.

Microsoft's solutions seem to all be javascript based also so you would have the same problem with them.

I would say the best solution would be to always have a notice and real link on the page that would lead to a non Flash page. In fact I would think that you would already have that since many users would not want to use a Flash site. I know that when I hit a site that is Flash based I normally go someplace else if they do not give me an option. :)

Bit0Byte
11-21-2006, 12:55 PM
Thanks Shawn,

I will revisit Amara It seemed straight forward to me, however I did not get the code to work. Also, I have been hoping to find the time create the non Flash page for my own site...you comments are an incentive.

Ivey

wildjokerdesign
11-21-2006, 01:36 PM
Is it possible that your pages could not find the .js script that you uploaded? The instructions assume that the .js file well be in the same directory as the page you are calling it from. You could use an absolute path instead of a relative one if you like.

Example:

<script type="text/javascript" src="/ieupdate.js"></script>
By adding the forward slash at the begining of the file name you are telling the browser that the file well be found at your public root i.e. server - /var/www/html directory.

The other thing you might have miss understood is that the call above would go after the closing tag </object> of the last flash object you have on the page.

artbuilders
12-20-2006, 10:59 AM
You can try SWFObject. It appears to be what youtube, et al, are using (and a billion dollars can't be wrong... ;)

It's pretty straighforward to use. First embed script in head tags:

<script type="text/javascript" src="/scripts/swfobject.js"></script>

Then add the following where you want your flash movie to appear:


<div id="flashcontent">
This text is replaced by the Flash movie.
</div>
<script type="text/javascript">
var so = new SWFObject("movie.swf", "mymovie", "300", "200", "7", "#FFF");
so.write("flashcontent");
</script>
SWFObject's built-in detection can be bypassed by passing a variable on the link to a page containing your Flash MC.

<a href="mypage.html?detectflash=false">Click Here to See My Brilliant Movie</a>
In terms of getting around Javascript completly, it's probably not realistic. I think with the surge of AJAX, users will be challenged to not enable js. Besides, there's been other attempts at workarounds (using only object tags, etc) but none of them appear to have really held up. So back to JS...

For a more detailed discussion and SWFObject script, go to http://blog.deconcept.com/swfobject/

If anyone else has suggestions, I'd love to hear them. I have quite a few sites I'm going to have to retro fit soon...