...

View Full Version : provide alternate content for browsers/devices without Flash



eabigelow
09-20-2011, 11:04 PM
Hi--

I have a quiz embedded on my site that originates elsewhere (QuizRevolution.com) and is embedded on my site via a link (plus some other code), part of that code being in an iframe. The quiz contains YouTube videos that, because of how the quiz is set up by QuizRevolution, will not play in browsers/devices without Flash (for example, the iPad).

What I would like to do is put some script on my site that will load a SECOND quiz from QuizRevolution (this one without video) for browsers/devices without Flash. This second quiz will substitute for the first one.

Does anyone know how to do this? The tricky part seems to be how I have embedded the quiz in my site, so I have included that part of the page here:

<!--QUIZ BEGINS-->

<article id="page_7c">
<div class="box" id="page1">
<a href="#page_1" class="close"></a>
<div class="wrapper pad_bot1">
<div class="grid_16 prefix_4">

<p></p>

<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTUzNDA1NTM1MjAmcHQ9MTMxNTM*MDU1NTUwMCZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe id=test src="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos">test_your_knowledge_about_ufos</a></iframe>


</div>
</div>
</div>
</article>


<!--QUIZ ENDS-->

Many thanks for any help! I am entirely stupid when it comes to coding, so if you could be specific in your suggestions, that would be really terrific. Again, thanks!

VIPStephan
09-20-2011, 11:53 PM
As far as I know YouTube provides videos for all platforms, either using Flash or HTML5 video, depending on device/support.

eabigelow
09-21-2011, 12:06 AM
Thanks for the reply. Yes, they do, and under normal circumstances, there would not be a problem. But the way QuizRevolution has embedded YouTube videos in the quizzes results in them not appearing at all in non-Flash environments. Which means (I think) that I need to provide alternate content, that is, another quiz without videos...

blaze4218
09-21-2011, 01:10 AM
Because your pulling content from the quiz site you don't really have the option of choosing how the youtube video is served, but I'm pretty sure you've already resigned yourself to that. Personally I avoid flash like the plague, so I had to google this one for you :)
What I can tell you right off the bat is that you need to try and detect flash; then, depending on whether or not it's available provide the appropriate version of the quiz. I found the following on flash detection:


<SCRIPT LANGUAGE=JavaScript1.1>
<!--
// courtesy of http://www.kirupa.com/developer/mx/detection.htm

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 ) { // DO THIS FOR FLASH
window.location.replace("http://www.kirupa.com/flash.htm");
} else{ // DO THIS FOR NON-FLASH
window.location.replace("http://www.kirupa.com/noflash.htm");
}
//-->

</SCRIPT>

but we're going to change that up a bit...
You have two options:
1) Hard-Code the iframe to the non-flash quiz, then detect if the browser has flash, and if it does- change the iframe to the flash version
2) Insert the iframe correctly the first time through the DOM via javascript

The second option has the benefit of giving the right code the first time. But if a browser doesn't have flash, isn't it possible that it also doesn't have JS enabled? If this is the case the user gets neither... :(
The first version ensures that in an edge-case scenario the user at least gets some version of the quiz. But this also means that you are going to get at least a partial load of the lesser quiz before flash users get redirected to the *cool* version.
Personally I like the first better, so I'm going to give you my take on that.
Script I found-Your Code-My modifications


<SCRIPT LANGUAGE=JavaScript1.1>
<!--
// courtesy of http://www.kirupa.com/developer/mx/detection.htm
function FLASH_CHECK(){
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 ) { // DO THIS FOR FLASH
document.getElementById('test').src= other_quiz_url// go ahead and replace this with the url...
}
}

window.attachEvent("onload", FLASH_CHECK);
//-->

</SCRIPT>

<!--QUIZ BEGINS-->

<article id="page_7c">
<div class="box" id="page1">
<a href="#page_1" class="close"></a>
<div class="wrapper pad_bot1">
<div class="grid_16 prefix_4">

<p></p>

<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTUzNDA1NTM1MjAmcHQ9MTMxNTM*MDU1NTUwMCZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe id=test src="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos">test_your_knowledge_about_ufos</a></iframe>


</div>
</div>
</div>
</article>


<!--QUIZ ENDS-->

Now if that flash detection script doesn't work, you can find lots more by googling "flash detection". After that the same principles should apply: the script will usually tell you where to put your code for when flash exists/doesn't-exist then you add your document.getElementById('test').src = quiz_url line

eabigelow
09-21-2011, 01:18 AM
Wow, This is impressive! I will try this out ASAP but in the meantime please accept my thanks for such a detailed and thorough answer!

eabigelow
09-21-2011, 04:27 AM
Hi, I have been poking around a bit with this, and I am running into a problem. Where you say to insert "src= other_quiz_url"... the original script I get from QuizRevolution for the quiz is not just a src but other stuff as well, plus 1-2 more srcs... OR do you intend for visitors to go off-site to get the quiz?

Here is the code again to embed the quiz:

<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTUzNDA1NTM1MjAmcHQ9MTMxNTM*MDU1NTUwMCZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe id=test src="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos">test_your_knowledge_about_ufos</a></iframe>


That's everything I need to embed their quiz. In the past, I tried removing some of that script, but then the quiz stopped working.

Also, now that I have been thinking about it, I almost prefer the option of delivering the Flash version first and then, if they don't have Flash, bumping them to the non-flash. But beggars can not be choosers--I will take whatever I can get!

blaze4218
09-21-2011, 04:48 AM
I see what they've done. The image serves as authentication (and since it's probably unique it is probably tracking your usage for statistical analysis...). No real problem there. Serving the flash version first and then subbing the non-flash is still option1, just in reverse. As long as you've considered your options you need to do what's best for your site...

But no I didn't
intend for visitors to go off-site to get the quiz? I just didn't realize that removing the img would break the script...

So what you need to do is replace the src for both the image and the iframe. My first guess would be that you can do that by adding an ID to your image and then repeating our solution for the other element.



document.getElementById('imgtest').src= "www.imageurl.com"
document.getElementById('test').src= "www.iframeurl.com"

Just in case, put the image first, trying to load the iframe first might check for the image, and if you are still waiting for the image to load it could fail.

blaze4218
09-21-2011, 04:54 AM
Oh, except when I modified the script I removed the part where it said what to do if you don't have flash because we weren't using it...
Slight mod in red :)


<SCRIPT LANGUAGE=JavaScript1.1>
<!--
// courtesy of http://www.kirupa.com/developer/mx/detection.htm
function FLASH_CHECK(){
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 ) { // DO THIS FOR Non-FLASH
document.getElementById('test').src= other_quiz_url// go ahead and replace this with the url...
}
}

window.attachEvent("onload", FLASH_CHECK);
//-->

</SCRIPT>

<!--QUIZ BEGINS-->

<article id="page_7c">
<div class="box" id="page1">
<a href="#page_1" class="close"></a>
<div class="wrapper pad_bot1">
<div class="grid_16 prefix_4">

<p></p>

<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTUzNDA1NTM1MjAmcHQ9MTMxNTM*MDU1NTUwMCZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe id=test src="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos">test_your_knowledge_about_ufos</a></iframe>


</div>
</div>
</div>
</article>


<!--QUIZ ENDS-->

blaze4218
09-21-2011, 05:17 AM
Sorry that I didn't run a test on that script I gave you, I usually do, I just didn't have the time earlier. I've tested it now, and it works fine. I couldn't test the whole solution though, because you didn't supply both of the quizzes. Assuming they are mostly identical, the script I gave you should work except for one typo on my part window.attachEvent("onload", FLASH_CHECK); should be window.attachEvent("onload", FLASH_CHECK());

If you still can't get it to work post both quizzes for comparison, maybe additional modifications are necessary... Or even better still, post your revision of the sample I provided (the full code)

eabigelow
09-21-2011, 08:56 PM
Sorry--I have been out of touch here (busy at work). I will try to get to this as soon as possible. Many, many thanks for your help on this. I will post back....

eabigelow
09-21-2011, 09:33 PM
Hi. I have tested it in Safari (with add-ons disabled), and yes, it does deliver the alternate content. That is very cool, but unfortunately, the alternate content pops up on the index page rather than being hidden, as it should be onload (the alternate content also pops up in Firefox, too, which does have Flash, so there seems to be a problem there). Either way, my guess is that (1) it is not appearing within the iframe for some reason, and (2) the detector is not noticing that my Firefox has Flash (I am on a Mac)?

Here is the code as I have put it on the page (the JS is not in the head, but in the same part of the body as the embedded quiz):

<SCRIPT LANGUAGE=JavaScript1.1>
<!--
// courtesy of http://www.kirupa.com/developer/mx/detection.htm
function FLASH_CHECK(){
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 ) { // DO THIS FOR Non-FLASH
document.getElementById('imgtest').src= "http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTY2MzIxMTMyMDMmcHQ9MTMxNjYzMjExNDkzMyZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif"
document.getElementById('test').src= "http://www.quizrevolution.com/act147547/mini/go/name_your_quiz"
}
}

window.attachEvent("onload", FLASH_CHECK());
//-->

</SCRIPT>
<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTY2MzIxMTMyMDMmcHQ9MTMxNjYzMjExNDkzMyZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe src="http://www.quizrevolution.com/act147547/mini/go/name_your_quiz" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147547/mini/go/name_your_quiz">name_your_quiz</a></iframe>

<!--QUIZ BEGINS-->

<article id="page_7c">
<div class="box" id="page1">
<a href="#page_1" class="close"></a>
<div class="wrapper pad_bot1">
<div class="grid_16 prefix_4">

<p></p>

<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTUzNDA1NTM1MjAmcHQ9MTMxNTM*MDU1NTUwMCZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe id=test src="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos">test_your_knowledge_about_ufos</a></iframe>


</div>
</div>
</div>
</article>


<!--QUIZ ENDS-->

Here is the full script for embedding the second quiz:


<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTY2MzIxMTMyMDMmcHQ9MTMxNjYzMjExNDkzMyZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe src="http://www.quizrevolution.com/act147547/mini/go/name_your_quiz" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147547/mini/go/name_your_quiz">name_your_quiz</a></iframe>

And here is the URL for the test page for the site:


http://www.webyarns.com/ABCsofUFOs/site/alt.html

And the URL for what the site should look like onload:


http://www.webyarns.com/ABCsofUFOs/site/index.html

Just so you know, because of a glitch in Firefox, a while ago I added a bit of script to refresh the iframe where the quiz appeared. Without the refresh, the "start" button did not appear in Firefox. Go figure...

And that code:


<script type="text/javascript">
function refreshIframe(el) {
var f = document.getElementById(el)
var rsrc = f.src
f.src="about:blank"
f.src=rsrc
}
</script>

As always (am I repeating myself?) many thanks for your help!

blaze4218
09-21-2011, 10:00 PM
the alternate content pops up on the index page rather than being hidden, as it should be onload
You would have done well to mention before that you needed it to stay hidden when it first loads... iframes have funny behaviors in some situations, like overriding their css when the src changes, or not acting on the z-index attribute... 3 solutions to that would be to
1) re-assert the "display:none" right after you change the source
2) display both content's in html with "display:none" and use your detection script to make one of them "display:inline" or "display:block"
3) don't call your FLASH_CHECK() function until you would like to show the quiz

As for the
(2) the detector is not noticing that my Firefox has Flash issue, it sounds like the detection script is not cross-browser compatible. Tell you what, why don't you "help me, to help you" and google "flash detection" or "flash detection cross browser compatible", or something similar, and find one you like that you can install easily and we can work on that one together...

EDIT:
actually, solution 2 would require not being called until you would like to show your quiz also, so not as good as solution 3...

eabigelow
09-22-2011, 12:46 AM
First, apologies for the oversight concerning the necessity for iframes. I tried to be as thorough as possible in my explanations, but this part slipped by me.

I am thinking now, would it be easier simply to have two sites and just forward people with Flash to one and those without Flash to another? So I would have a landing page with a script on it that will re-direct the visitor to the appropriate site?

blaze4218
09-22-2011, 02:03 AM
Not really, because that would require first detecting which browsers need to be directed to which page, and since we've solved everything but that... Your just coming full circle back to the same problem! I'm surprise noone else has chimed in with a suggestion on how to detect flash :(

eabigelow
09-22-2011, 03:05 AM
Hi--

I have tried this bit of code below on my current index.html page and it does seem to redirect to index2.html for Safari and Firefox if they don't have Flash. I have not tried it for the iPad, though, or IE without Flash.

I realize this is not the best way to go, but for the meantime (until quizrevolution gets their act together), this would redirect those without Flash to index2.html, where I could serve them the quiz without videos.

Here is the code, which I know is old (JS 1.1!), but I imagine I can find a JS 2 equivalent.

<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 ) {
window.location.replace("http://www.webyarns.com/ABCsofUFOs/site/index.html");
} else{
window.location.replace("http://www.webyarns.com/ABCsofUFOs/site/index2.html");
}
//-->

</SCRIPT>

Does this seem reasonable to you, or am I missing something?

blaze4218
09-22-2011, 07:22 AM
Wow
So, uh, it wasn't the detection script per se. It did work for like 10 different scenarios that I tested, It just didn't want to edit those elements... Go figure (I could make the edits from outside of the script even!!!).
But I'm not one for defeat, and since your site requires that the quiz start hidden and be revealed later via js, obviously you can take the hit of a script that 100% requires js. (your clearly not worried about ppl turning it off...)
That being said, I reverted to a technique from when I first started manipulating pages post-load via js, a little hackneyed, but it gets the job done. Besides sometimes the simplest solution is the best ;)
*Note- I've tested this in all the browsers I have, and my iPhone. Works the same across the board :D




<!--QUIZ BEGINS-->

<article id="page_7c">
<div class="box" id="page1">
<a href="#page_1" class="close"></a>
<div class="wrapper pad_bot1">
<div class="grid_16 prefix_4">

<p></p>
<div id="tester">

</div>

</div>
</div>
</div>
</article>


<!--QUIZ ENDS-->
<SCRIPT>
<!--
// courtesy of http://www.kirupa.com/developer/mx/detection.htm
function FLASH_CHECK(){
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.getElementById('tester').innerHTML = '<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTUzNDA1NTM1MjAmcHQ9MTMxNTM*MDU1NTUwMCZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe id=test src="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147691/mini/go/test_your_knowledge_about_ufos">test_your_knowledge_about_ufos</a></iframe> '
} else{
document.getElementById('tester').innerHTML = '<img style="visibility:hidden;width:0px;height:0px;" border=0 width=0 height=0 src="http://c.gigcount.com/wildfire/IMP/CXNID=2000002.0NXC/bT*xJmx*PTEzMTY2MzIxMTMyMDMmcHQ9MTMxNjYzMjExNDkzMyZwPTIwNDMyMSZkPSZnPTEmbz*wMWFhMzNjMDI4ZWM*NjNmYTZh/NGU1M2FiNzRmZTZlMSZvZj*w.gif" /> <iframe src="http://www.quizrevolution.com/act147547/mini/go/name_your_quiz" width="380" height="400" frameborder="0" scrolling="no" name="mystudiyoIframe" title="QuizRevolution.com"><a href="http://www.quizrevolution.com/act147547/mini/go/name_your_quiz">name_your_quiz</a></iframe>';
}
}
//-->
</SCRIPT>
<button onclick="FLASH_CHECK();">Quiz me Baby!</button>

If I could leave you with one final thought...

avoid flash like the plague
Now if you'll excuse me I think I'll hop in the shower. I need to wash the smell of non compliance off of me and burn these clothes lest I become recontaminated.

eabigelow
09-22-2011, 09:00 PM
Hi, that has worked like a charm! Having a friend test it on their iPad, and waiting for her report, but looking good so far.

Seriously, you spent a lot of time helping me out here. I very much appreciate it. You seem to have some really good skills. Mine are solely in Flash. In fact, as a Net artist, for the past ten years, that's all I have been using (I can hear you growling on the other end). Flash may drain batteries and put a heavy load on cpus, but there's nothing better for creating full-blown art projects on the web. If you want to check out some of my work, it's at http://www.webyarns.com. This was my first foray into html, etc. since 1999.

I was wondering, would you consider doing a couple of further things on this current site of mine and have me pay you for your time? I do not know how expensive it would be, but there are a few wrinkles I still need to work out. If you think you might be into something like that, I could send you the details. Mostly it would be checking to make sure minimal errors are generated on other browsers (like IE), and there is a background image sizing problem in the iPad, and some problems with audio. Right now, I am currently working on a google map that does not show up on the site in the iPad.

Just let me know, and again, my thanks!

blaze4218
09-22-2011, 09:25 PM
Well I'm glad to help. I'm really just a novice at this, unlike the other people that do this professionally. This site is great for do-it-yourselfers but if you need some further help you can pm me here http://www.codingforums.com/member.php?u=21905 and I'll get you my contact info.
P.S. I'm sure if I had any artistic talent whatsoever I would drool over flash too, and it does have it's upsides. But with all the security holes it can open to even the novice programmer, I prefer to only enable it on trusted sites as an end-user.

Happy Coding!



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum