(Vintage stuff, from the heyday of Flash)

“Click to activate and use this control box”

(A workaround for Web designers and developers)

By Michael Scannell

It only takes a minute!

Why the irritating message?

Why do you have to click twice to select a Flash menu option?
You must have been there. You click on a menu option. Nothing happens. Then you notice the floating message: “Click to activate and use this control box.” You click again—and the thing works.
Or maybe it's an animation that doesn't start. Until you notice the stupid message and you click just to get the thing going.
What's going on?

Michael Scannell

Michael is the Web Costa Blanca webmaster.

He has worked on many Web sites, both large and small, in Spain and the UK.

Is it the Web site developer's fault?
Not really. When she or he first crafted their Flash menu or animation, everything worked fine. And nothing has gone wrong with the Flash player.
So what has happened?
A group of Americans, businessmen rather than inventors, decided to see if they could ‘patent’ a mechanism which had been used for years on browsers. (Well, in America, some businessmen have been trying to ‘patent’ Basmati rice, which has been grown by the farmers of the sub-continent for centuries.)
This being America, whose patron saint is Al Capone, they succeeded.
So they went on and sued Microsoft for using their ‘patented’ mechanism—which Microsoft had been using for years before this grant of a patent.
Microsoft contested the case, but this being America, whose patron saint (you get the idea), they lost. The bunch of people who had taken out this ‘patent’ licked their lips, in anticipation of huge amounts of loot. (Well that's why they'd dreamed up this wheeze in the first place.)
(This is, of course, my version of the story. For a more objective summary, you might like to check the Wikipedia article on the patent.)
Did Microsoft cough up?
No. They decided to use another mechanism, involving ActiveX, for which they themselves hold the patent.
The downside is that we all have to click to activate the object—unless we are on the page of a more savvy developer.

As a Web developer, you can fix it

  1. In your favourite editor, open the Web page where you have Flash animations and/or other <object> tags.
  2. Immediately after the final </object> tag in your page, enter this line:

    <script type="text/javascript src="activate-objects.js"></script>

    By 'immediately' I mean before you use any new opening tags. You can close a <div> element, for example, and have as many blank lines as you like.
  3. Create the activate-objects.js file. Either enter the following lines of JavaScript in a blank file:

    var all_objects = document.getElementsByTagName( "object" );
    for ( var i = 0; i < all_objects.length; i++ )	{
    	all_objects[i].outerHTML = all_objects[i].outerHTML;
    }
    
    and save the file, or download it from the Web Costa Blanca site now. (Right-click on the link and 'Save Target As…'.)
  4. Upload the two files to the same directory on your website—or make the usual addressing adjustments.
  5. Repeat steps 1 and 2 as often as you need. Visitors to your Web site should never see “Click to activate and use this control box” again.

Acknowledgement

I have made some small changes in the code to suit my own programming style, and carried out some experiments with elements and tags myself, but I found the essence of this workaround on the Mix-FX site.

There are a number of alternative workarounds on the Wikipedia page already mentioned.

(2008 update) The latest versions of Dreamweaver will also provide you with an automatic solution.

Client Log in | Terms of Service | Privacy Policy | Articles and Tutorials | Resources | Site Map | Site Index

Valid HTML 4.01 Strict  Valid CSS!