/*
function writeFlash(path, width, height){
document.write('<object classid="clsid:D27CDB6E-AE6D-11CF-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" border="0" width="'+width+'" height="'+height+'">');
document.write('<param name="movie" value="'+path+'">');
document.write('<param name="quality" value="High">');
document.write('<embed src="'+path+'" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+width+'" height="'+height+'" quality="High"></object>');
}

function writeInnerFlash(id,path, width, height){
newhtml='<object classid="clsid:D27CDB6E-AE6D-11CF-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" border="0" width="'+width+'" height="'+height+'">';
newhtml+='<param name="movie" value="'+path+'">';
newhtml+='<param name="quality" value="High">';
newhtml+='<embed src="'+path+'" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+width+'" height="'+height+'" quality="High"></object>';
document.getElementById(id).innerHTML=newhtml;
}
*/

function writeFlash(path, width, height){
document.write('<object type="application/x-shockwave-flash" data="'+path+'" width="'+width+'" height="'+height+'">');
document.write('<param name="movie" value="'+path+'" /><param name="wmode" value="transparent" /><param name="quality" value="high" /></object>');
}
function writeInnerFlash(id,path, width, height){
newhtml='<object type="application/x-shockwave-flash" data="'+path+'" width="'+width+'" height="'+height+'">';
newhtml+='<param name="movie" value="'+path+'" /><param name="quality" value="high" /></object>';
document.getElementById(id).innerHTML=newhtml;
}



function FP_swapImg() {//v1.0
 var doc=document,args=arguments,elm,n; doc.$imgSwaps=new Array(); for(n=2; n<args.length;
 n+=2) { elm=FP_getObjectByID(args[n]); if(elm) { doc.$imgSwaps[doc.$imgSwaps.length]=elm;
 elm.$src=elm.src; elm.src=args[n+1]; } }
}

function FP_preloadImgs() {//v1.0
 var d=document,a=arguments; if(!d.FP_imgs) d.FP_imgs=new Array();
 for(var i=0; i<a.length; i++) { d.FP_imgs[i]=new Image; d.FP_imgs[i].src=a[i]; }
}

function FP_getObjectByID(id,o) {//v1.0
 var c,el,els,f,m,n; if(!o)o=document; if(o.getElementById) el=o.getElementById(id);
 else if(o.layers) c=o.layers; else if(o.all) el=o.all[id]; if(el) return el;
 if(o.id==id || o.name==id) return o; if(o.childNodes) c=o.childNodes; if(c)
 for(n=0; n<c.length; n++) { el=FP_getObjectByID(id,c[n]); if(el) return el; }
 f=o.forms; if(f) for(n=0; n<f.length; n++) { els=f[n].elements;
 for(m=0; m<els.length; m++){ el=FP_getObjectByID(id,els[n]); if(el) return el; } }
 return null;
}




var toill=new Array();
var torabb=new Array();
oggetti = new Object();

function illumina(imm){
 window.clearTimeout(torabb[imm.src]);
 oggetti[imm.src]=imm;
 if((imm.filters)&&(imm.filters.alpha)){//se è IE
  imm.filters.alpha.opacity-=5;
  if (imm.filters.alpha.opacity>=70) {toill[imm.src]=window.setTimeout("illumina(oggetti['"+imm.src+"'])", 0);}
 } else if (imm.style.MozOpacity){//se non è IE ma è Firefox
  imm.style.MozOpacity-=0.03;
  if (imm.style.MozOpacity>=0.7) {toill[imm.src]=window.setTimeout("illumina(oggetti['"+imm.src+"'])", 0);}
 }
}
 

function rabbuia(imm){
 window.clearTimeout(toill[imm.src]);
 if(imm.filters){// se è IE
  oggetti[imm.src]=imm;
  imm.filters.alpha.opacity+=5;
  if (imm.filters.alpha.opacity<100) {torabb[imm.src]=window.setTimeout("rabbuia(oggetti['"+imm.src+"'])", 0);}
 } else if (imm.style.MozOpacity){//se non è IE ma è Firefox
  oggetti[imm.src]=imm;
  imm.style.MozOpacity=Math.min(parseFloat(imm.style.MozOpacity)+0.03, 0.99)
  if (imm.style.MozOpacity<0.99) {torabb[imm.src]=window.setTimeout("rabbuia(oggetti['"+imm.src+"'])", 0);}
 }
}