/* Example script that goes with some of the examples as example javascript */
/* feel free to use these example scripts */

var outtojs = function (){tellingflash("complexer");};

var tellingflash = function (thisid)
{
  try{var fcontenter=window.document.getElementById(thisid);}catch(e)
  {try{var fcontenter=window.document.thisid;}catch(e){var movie=thisid;
       if (navigator.appName.indexOf("Microsoft")!=-1 || navigator.appName.indexOf("MSIE")!=-1){ 
          if (window.document[movie])
          {var fcontenter=window.document[movie];}else{var fcontenter=window[movie];};}else{
         if (document.embeds[movie])
         {var fcontenter=document.embeds[movie];}else{var fcontenter=document[movie];};
       }
    }
  }try{fcontenter.backfromjs();}catch(e){var nojstoflerthreeas="yes";}
};

var bridgecrosser = function(thisfile)
{
  try{var fcontenterj=window.document.getElementById('tbridge');}catch(e){
    try{var fcontenterj=window.document.tbridge;}catch(e){
       var movie=tbridge;
       if (navigator.appName.indexOf("Microsoft")!=-1 || navigator.appName.indexOf("MSIE")!=-1){ 
          if (window.document[movie])
          {var fcontenterj=window.document[movie];}else{var fcontenterj=window[movie];};}else{
         if (document.embeds[movie])
         {var fcontenterj=document.embeds[movie];}else{var fcontenterj=document[movie];};
       }
    }
  }try{fcontenterj.jsinitiate(thisfile);}catch(e){var nojstoflerthreeas="yes";}
};

var getinputthencross = function() {
//some validation not shown in the tutorial
//the rule of thumb is to never trust your sites users
var numberz = new RegExp("[0-9]{1,}", "i");
var notneeds = new RegExp("[\/\)\(\* a-zA-Z]{1,}", "i"); 
var firstnum = document.getElementById("fnum").value;
var secondnum = document.getElementById("snum").value;
if (firstnum.match(notneeds) || secondnum.match(notneeds) || !firstnum.match(numberz) ||
!secondnum.match(numberz) || firstnum.length>25 || secondnum.length>25)
{document.getElementById('fjholder').innerHTML="only numbers please";}
else {bridgecrosser("responsivepage.php?numf="+firstnum+"&nums="+secondnum);}
};

var thedatagot = function(fjdata) {document.getElementById('fjholder').innerHTML=fjdata;loaddone();};
var alertthese = function(words) {alert(words);};

//end examples javascript
function doneclear() {document.getElementById('doneview').innerHTML=" "; }
function readyloadstop() {setTimeout("doneclear()", "1000"); }
function loaddone() {var naverly=navigator.appVersion+navigator.appName;
if (naverly.indexOf('Opera')==-1 && naverly.indexOf('Internet Explorer')==-1 && naverly.indexOf('Safari')==-1)
{document.getElementById('doneview').innerHTML='<img src="images/donerimg.gif"></img>';readyloadstop();} };




function handraise(student) {document.getElementById(student).yourhere();}

function gotop(ofthis) {
try {document.getElementById('theFlash').scrollIntoView();} 
catch (e) {document.getElementById('theFlash').focus();} 
}

var flashvars = {};var params = {};var atts = {};


function iniBrowserFixesAndParams() {

var nap = navigator.appName+navigator.appVersion+"";
if (nap.indexOf("MSIE")!=-1 || nap.indexOf("InternetExplorer")!=-1) {
if (fixie <=6) { var images = document.getElementsByTagName("img");
images[0].src = "images/activedentail.gif";images[1].src = "images/themeforesttail.gif";
images[2].src = "images/graphicrivertail.gif";images[3].src = "images/twitsmall.gif"; }
if (fixie <= 7) { var ex = document.getElementById("examplesa");
ex.onmouseover = function () {this.style.height = "500px";}
ex.onmouseout = function () {this.style.height = "20px";} } }


params.menu = "true";params.quality = "high";
params.wmode = "transparent";
params.allowscriptaccess = "sameDomain";params.allowfullscreen = "false";params.bgcolor = "000000";


}

