[Pro] Alternative image if Flash not present

There is a lot of Flash hate at the moment, and bearing in mind the issues about iPad and iPhone.

I have a project where part of the page need to be Flash. But I need to detect if its present, and if not serve an alternative image in its place on the page instead.

What is “best accessibility practice” to do this ~ can’t find anything about this on Google apart for the usual serve a different page, or prompt to load a plugin.

David


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

I think it is a Flash Sniffer that you are looking for

David


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

The usual Flash sniffer would prompt to get the Flash Plugin or go to another page.

In this case its replace content in a page

And what is “best practice” e.g. does serving alternative content via Javascript cause an issue with Google.


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Is it a problem redirecting to another page with alternate content? That is just what the iPhone redirect action does.

But as to best practice using a javascript redirect- that I don’t know.

D


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Hi David

As my orginal question: “I have a project where part of the page need to be Flash. But I need to detect if its present, and if not, serve an alternative IMAGE in its place on the page instead.”

e.g. NOT a different page ~ the same page.

David


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

On Nov 20, 2010, at 7:51 AM, David Owen wrote:

I have a project where part of the page need to be Flash. But I need
to detect if its present, and if not serve an alternative image in
its place on the page instead.

From A List Apart: If the browser can’t play MIME type objects then
it will default to the next child element, in this case the
“noflash.gif” in the tag below. Would seem a way to skirt the no
javascript issue too.

I’ve never used this but it might be worth a look. Sounds simple
enough. I also found some server-side techniques to insert alternative
content but it seems like a load of work for what you need.

<object type="application/x-shockwave-flash
data="c.swf?path=movie.swf"
width="400" height="300">
<param name="movie"
value="c.swf?path=movie.swf" />
<img src="noflash.gif"
width="200" height="100" alt="" />
</object>

Todd


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

The Flash Extras Action (built in to Freeway since version 2) lets you
set this up in a nice easy Freeway-style workflow. Select the
replacement image through the Action interface while you have the
Action applied to your Flash movie.

Walter

On Nov 20, 2010, at 10:40 AM, David Owen wrote:

Hi David

As my orginal question: “I have a project where part of the page
need to be Flash. But I need to detect if its present, and if not,
serve an alternative IMAGE in its place on the page instead.”


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Thanks Walter, did not know about that bit of the action. I shall take a look.

David

On 20 Nov 2010, at 16:11, Walter Lee Davis email@hidden wrote:

The Flash Extras Action (built in to Freeway since version 2) lets you set this up in a nice easy Freeway-style workflow. Select the replacement image through the Action interface while you have the Action applied to your Flash movie.

Walter

On Nov 20, 2010, at 10:40 AM, David Owen wrote:

Hi David

As my orginal question: “I have a project where part of the page need to be Flash. But I need to detect if its present, and if not, serve an alternative IMAGE in its place on the page instead.”


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

The Flash Extra Action only has three options:

Scale movie or protect movie, Change BG colour. No replacement image

Am I missing something?


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

I’ll be darned. I wonder when that was removed. I haven’t used Flash
in ages, but I remember setting this up and having it work really
simply.

Walter

On Nov 20, 2010, at 12:02 PM, David Owen wrote:

The Flash Extra Action only has three options:

Scale movie or protect movie, Change BG colour. No replacement image

Am I missing something?


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

As my orginal question: “I have a project where part of the page need to be Flash. But I need to detect if its present, and if not, serve an alternative IMAGE in its place on the page instead.”

I did appreciate that the ideal solution was to serve alternate content in the existing page. But if that is not easily achieved is it such a big deal to serve an alternate page.

You may have a specific reason why it has to be done that way.

D


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Walter,
What do you use instead of Flash?

Thanks,
Jacob

On Nov 20, 2010, at 11:26 AM, Walter Lee Davis wrote:

I’ll be darned. I wonder when that was removed. I haven’t used Flash in ages, but I remember setting this up and having it work really simply.

Walter

On Nov 20, 2010, at 12:02 PM, David Owen wrote:

The Flash Extra Action only has three options:

Scale movie or protect movie, Change BG colour. No replacement image

Am I missing something?


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

JavaScript. Lots and lots of JavaScript. ScriptAculoUs does nearly
everything that you can do in Flash, and it does so with far less
browser overhead (so it will run happily on your iDevice). About the
only thing that Flash can do reliably better than JavaScript (besides
crash your browser or open security holes) is synchronize audio to
motion graphics. If that’s your thing, then stick with Flash. But
realize you are alienating tens of millions of people who use iPhones
or iPod touch or iPad, Android, Blackberry, etc. – who won’t see
anything besides an ugly hole in your page.

Walter

On Nov 20, 2010, at 2:03 PM, Jacob Cichy wrote:

Walter,
What do you use instead of Flash?

Thanks,
Jacob

On Nov 20, 2010, at 11:26 AM, Walter Lee Davis wrote:

I’ll be darned. I wonder when that was removed. I haven’t used
Flash in ages, but I remember setting this up and having it work
really simply.

Walter

On Nov 20, 2010, at 12:02 PM, David Owen wrote:

The Flash Extra Action only has three options:

Scale movie or protect movie, Change BG colour. No replacement image

Am I missing something?


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

This is the dilemma I’m in at the moment, wanting some quite complex animation on a page, Flash having the tools available to very quickly achieve the end game with little fuss. But then there is iOS on the iPhone iPad etc. :frowning:

I believe were in the middle of a transition from Flash to software tools to achieve this in the browser using JavaScript, I do wish there were some software app/tools to help with the code process above the basic stuff you see.

Walter have you seen the Ai > canvas plugin?

http://visitmix.com/labs/ai2canvas/

David

On 20 Nov 2010, at 19:11, Walter Lee Davis email@hidden wrote:

But realize you are alienating tens of millions of people who use iPhones or iPod touch or iPad, Android, Blackberry, etc


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

No, but it looks extremely cool. Adobe showed off some early alpha
tools to convert Flash into HTML5 animation, and that seemed to work
really well also. What I would love is if someone would come up with a
much nicer interface than Flash’s, which would then write JavaScript
or other animation formats like canvas. What would really hurt is if
Adobe got their motor oil (Flash, and its hateful design UI) in my
peanut butter (JavaScript).

Walter

On Nov 20, 2010, at 2:34 PM, David Owen wrote:

Walter have you seen the Ai > canvas plugin?


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

OK - I found this bit of script and inserted in a markup on this page http://deltadesign.co/boutique_images/boutiqueimages.html

Seems to work on my iPad and iMac - who knows about Windoze - haven’t tried it yet.


<SCRIPT LANGUAGE=JavaScript1.1>
<!--
var MM_contentVersion = 6;
var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
if ( plugin ) {
		var words = navigator.plugins["Shockwave Flash"].description.split(" ");
	    for (var i = 0; i < words.length; ++i)
	    {
		if (isNaN(parseInt(words[i])))
		continue;
		var MM_PluginVersion = words[i]; 
	    }
	var MM_FlashCanPlay = MM_PluginVersion >= MM_contentVersion;
}
else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 
   && (navigator.appVersion.indexOf("Win") != -1)) {
	document.write('<SCR' + 'IPT LANGUAGE=VBScript> n'); //FS hide this from IE4.5 Mac by splitting the tag
	document.write('on error resume next n');
	document.write('MM_FlashCanPlay = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." & MM_contentVersion)))n');
	document.write('</SCR' + 'IPT> n');
}
if ( MM_FlashCanPlay ) {
		document.write('<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"');
	document.write('  codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" ');
	document.write(' ID="script" WIDTH="300" HEIGHT="200" ALIGN="">');
	document.write(' <PARAM NAME=movie VALUE="script.swf"> <PARAM NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE=#FFFFFF>  '); 
	document.write(' <EMBED src="script.swf" quality=high bgcolor=#FFFFFF  ');
	document.write(' swLiveConnect=FALSE WIDTH="300" HEIGHT="200" NAME="script" ALIGN=""');
	document.write(' TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">');
	document.write(' </EMBED>');
	document.write(' </OBJECT>');
} else{
	document.write('<IMG SRC="script.gif" WIDTH="300" HEIGHT="200" usemap="#script" BORDER=0>');
}
//-->
</SCRIPT><NOSCRIPT><IMG SRC="script.gif" WIDTH="300" HEIGHT="200" usemap="#script" BORDER=0></NOSCRIPT>

David


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Walt

I do believe Adobe is working on something (just can’t pinpoint where I read it) to release next year. Spurred on no doubt from the amount of Flash not being used or dropped as an option by designers. I have not used Flash animation for over a year now.

Bet Adobe’s offering won’t be cheap.

David

On 20 Nov 2010, at 19:38, Walter Lee Davis email@hidden wrote:

No, but it looks extremely cool. Adobe showed off some early alpha tools to convert Flash into HTML5 animation, and that seemed to work really well also. What I would love is if someone would come up with a much nicer interface than Flash’s, which would then write JavaScript or other animation formats like canvas. What would really hurt is if Adobe got their motor oil (Flash, and its hateful design UI) in my peanut butter (JavaScript).

Walter

On Nov 20, 2010, at 2:34 PM, David Owen wrote:

Walter have you seen the Ai > canvas plugin?


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Thanks David, I shall have a test with that.

Or I rethink and downgrade the Flash animation effects to manageable scriptaculous actions.

David

On 20 Nov 2010, at 19:39, “DeltaDave” email@hidden wrote:

OK - I found this bit of script and inserted in a markup on this page http://deltadesign.co/boutique_images/boutiqueimages.html

Seems to work on my iPad and iMac - who knows about Windoze - haven’t tried it yet.


<SCRIPT LANGUAGE=JavaScript1.1>
<!--
var MM_contentVersion = 6;
var plugin = (navigator.mimeTypes && navigator.mimeTypes["application/x-shockwave-flash"]) ? navigator.mimeTypes["application/x-shockwave-flash"].enabledPlugin : 0;
if ( plugin ) {
      var words = navigator.plugins["Shockwave Flash"].description.split(" ");
      for (var i = 0; i < words.length; ++i)
      {
      if (isNaN(parseInt(words[i])))
      continue;
      var MM_PluginVersion = words[i]; 
      }
  var MM_FlashCanPlay = MM_PluginVersion >= MM_contentVersion;
}
else if (navigator.userAgent && navigator.userAgent.indexOf("MSIE")>=0 
 && (navigator.appVersion.indexOf("Win") != -1)) {
  document.write('<SCR' + 'IPT LANGUAGE=VBScript> n'); //FS hide this from IE4.5 Mac by splitting the tag
  document.write('on error resume next n');
  document.write('MM_FlashCanPlay = ( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." & MM_contentVersion)))n');
  document.write('</SCR' + 'IPT> n');
}
if ( MM_FlashCanPlay ) {
      document.write('<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"');
  document.write('  codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" ');
  document.write(' ID="script" WIDTH="300" HEIGHT="200" ALIGN="">');
  document.write(' <PARAM NAME=movie VALUE="script.swf"> <PARAM NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE=#FFFFFF>  '); 
  document.write(' <EMBED src="script.swf" quality=high bgcolor=#FFFFFF  ');
  document.write(' swLiveConnect=FALSE WIDTH="300" HEIGHT="200" NAME="script" ALIGN=""');
  document.write(' TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer">');
  document.write(' </EMBED>');
  document.write(' </OBJECT>');
} else{
  document.write('<IMG SRC="script.gif" WIDTH="300" HEIGHT="200" usemap="#script" BORDER=0>');
}
//-->
</SCRIPT><NOSCRIPT><IMG SRC="script.gif" WIDTH="300" HEIGHT="200" usemap="#script" BORDER=0></NOSCRIPT>

David


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

Here’s something else to try. With Protaculous on your page, click
once on your Flash movie and note its ID (whatever is in the Title
field in the left-most tab of the Inspector).

Now draw an image box the same size as your Flash movie, and note its
ID as well.

In the top Function Body button in Protaculous, add this (substitute
the placeholder values for the real names you noted above):

$('myFlashMovie').down('object').insert($('myImage').remove());

If that doesn’t do it, then try:

$('myFlashMovie').down('object')insert($ 
('myImage').down('img').remove());

One of those ought to work. Make sure your image is exactly the same
size as the movie, and you should see this image only if the browser
doesn’t support Flash. All browsers support the object tag, but not
all browsers can load the content you put inside it. This image should
be covered up by the flash movie in browsers that support Flash
content, and revealed in the rest.

Walter

On Nov 20, 2010, at 3:10 PM, David Owen wrote:

Thanks David, I shall have a test with that.

Or I rethink and downgrade the Flash animation effects to manageable
scriptaculous actions.

David

On 20 Nov 2010, at 19:39, “DeltaDave” email@hidden wrote:

OK - I found this bit of script and inserted in a markup on this
page http://deltadesign.co/boutique_images/boutiqueimages.html

Seems to work on my iPad and iMac - who knows about Windoze -
haven’t tried it yet.


<SCRIPT LANGUAGE=JavaScript1.1>
<!--
var MM_contentVersion = 6;
var plugin = (navigator.mimeTypes &&  
navigator.mimeTypes["application/x-shockwave-flash"]) ?  
navigator.mimeTypes["application/x-shockwave- 
flash"].enabledPlugin : 0;
if ( plugin ) {
     var words = navigator.plugins["Shockwave  
Flash"].description.split(" ");
     for (var i = 0; i < words.length; ++i)
     {
     if (isNaN(parseInt(words[i])))
     continue;
     var MM_PluginVersion = words[i];
     }
 var MM_FlashCanPlay = MM_PluginVersion >= MM_contentVersion;
}
else if (navigator.userAgent &&  
navigator.userAgent.indexOf("MSIE")>=0
&& (navigator.appVersion.indexOf("Win") != -1)) {
 document.write('<SCR' + 'IPT LANGUAGE=VBScript> n'); //FS hide  
this from IE4.5 Mac by splitting the tag
 document.write('on error resume next n');
 document.write('MM_FlashCanPlay =  
( IsObject(CreateObject("ShockwaveFlash.ShockwaveFlash." &  
MM_contentVersion)))n');
 document.write('</SCR' + 'IPT> n');
}
if ( MM_FlashCanPlay ) {
     document.write('<OBJECT classid="clsid:D27CDB6E- 
AE6D-11cf-96B8-444553540000"');
 document.write('  codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version 
=6,0,0,0" ');
 document.write(' ID="script" WIDTH="300" HEIGHT="200" ALIGN="">');
 document.write(' <PARAM NAME=movie VALUE="script.swf"> <PARAM  
NAME=quality VALUE=high> <PARAM NAME=bgcolor VALUE=#FFFFFF>  ');
 document.write(' <EMBED src="script.swf" quality=high  
bgcolor=#FFFFFF  ');
 document.write(' swLiveConnect=FALSE WIDTH="300" HEIGHT="200"  
NAME="script" ALIGN=""');
 document.write(' TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer 
">');
 document.write(' </EMBED>');
 document.write(' </OBJECT>');
} else{
 document.write('<IMG SRC="script.gif" WIDTH="300" HEIGHT="200"  
usemap="#script" BORDER=0>');
}
//-->
</SCRIPT><NOSCRIPT><IMG SRC="script.gif" WIDTH="300" HEIGHT="200"  
usemap="#script" BORDER=0></NOSCRIPT>

David


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options

As a bit of a “proof of concept” and only using Freeway in built tools with not extra coding, you can go a long way creating a “Flash” like presentation:-

http://www.printlineadvertising.co.uk/demo/freeway/no-flash/index.html

David Owen { Freeway Friendly Web hosting and Domains }

http://www.ineedwebhosting.co.uk | http://www.PrintlineAdvertising.co.uk

On 20 Nov 2010, at 19:38, Walter Lee Davis wrote:

No, but it looks extremely cool. Adobe showed off some early alpha tools to convert Flash into HTML5 animation, and that seemed to work really well also. What I would love is if someone would come up with a much nicer interface than Flash’s, which would then write JavaScript or other animation formats like canvas. What would really hurt is if Adobe got their motor oil (Flash, and its hateful design UI) in my peanut butter (JavaScript).

Walter

On Nov 20, 2010, at 2:34 PM, David Owen wrote:

Walter have you seen the Ai > canvas plugin?


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options


dynamo mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options