<!-- 
function autoIframe(frameId){
        try{
                frame = document.getElementById(frameId);
                innerDoc = (frame.contentDocument) ? frame.contentDocument : frame.contentWindow.document;
                objToResize = (frame.style) ? frame.style : frame;
                objToResize.height = innerDoc.body.scrollHeight;
				
				//alert(innerDoc.body.scrollHeight)
        }
        catch(err){
                window.status = err.message;
        }
	
}




// Browser Slide-Show script.
// With image cross fade effect for those browsers that support it.
var slideCache = new Array();
function RunSlideShow(pictureName,imageFiles,displaySecs)
{
	var imageSeparator = imageFiles.indexOf(";");
	var nextImage = imageFiles.substring(0,imageSeparator);
	if (document.all)
	{
		document.getElementById(pictureName).style.filter="blendTrans(duration=2)";
		document.getElementById(pictureName).filters.blendTrans.Apply();
	}
	document.getElementById(pictureName).src = nextImage;
	if (document.all)
	{
		document.getElementById(pictureName).filters.blendTrans.Play();
	}
	var futureImages= imageFiles.substring(imageSeparator+1,imageFiles.length)
	+ ';' + nextImage;
	setTimeout("RunSlideShow('"+pictureName+"','"+futureImages+"',"+displaySecs+")",
	displaySecs*1000);
	// Cache the next image to improve performance.
	imageSeparator = futureImages.indexOf(";");
	nextImage = futureImages.substring(0,imageSeparator);
	if (slideCache[nextImage] == null) 
	{
		slideCache[nextImage] = new Image;
		slideCache[nextImage].src = nextImage;
	}
}

var cant=1;
var total=0;

function next(aeropuerto,count)
{
//if ((total==0)&(count!=0))
   total=count;
  if (cant < count)
  {	cant = cant + 1;
	myimagen=document.getElementById("imagenes");
	myimagen.style.filter="blendTrans(duration=2)";
    myimagen.filters.blendTrans(duration=1.5).Apply();
    myimagen.filters.blendTrans.Play();
    myimagen.src="images/"+aeropuerto+"/"+ (Math.abs(cant-1) % total) + ".jpg";
	document.getElementById("numerodefoto").innerHTML = cant;
	}
} 
  
function ant(aeropuerto,count)
{
//if ((total==0)&(count!=0))
//	  total=count;
  if (cant > 1)
  {	cant = cant - 1;
    myimagen=document.getElementById("imagenes"); 
	myimagen.style.filter="blendTrans(duration=2)";
    myimagen.filters.blendTrans(duration=1.5).Apply();
    myimagen.filters.blendTrans.Play();
	myimagen.src="images/"+aeropuerto+"/"+ (Math.abs(cant-1) % total) +".jpg";
	document.getElementById("numerodefoto").innerHTML =  cant;
   }
} 

//-->

