function switchHeader(url) {
	
 var header = document.getElementById("header");
 header.innerHTML="<img src='Images/pixel.gif' width=480 height=270>";
 header.style.background = "#000000 url('"+url+"') center no-repeat";
 scroll(0,0);	
}
function goURL(lang,v1,v2,v3) {
	
	location.href='?lang='+lang+'&pag_id='+v1;


}

function showVideo(url) {
	var html = "<object type='application/x-shockwave-flash' data='"+url+"' width=480 height=270><param name='movie' value='"+url+"'></object>";
	document.getElementById("header").innerHTML = html;
	scroll(0,0);	


}
function showFlv(url) {
	
	var html = "<iframe src='flashplayer/flvplayer.php?f="+url+"' width=480 height=270 frameborder=0 style='border:0;overflow: hidden'></iframe>";
	document.getElementById("header").innerHTML = html;
	scroll(0,0);	


}

function showPano(pano) {
	var html = "<iframe src='http://www.we-are.tv/AVE/VR_AVE/Collection/panoviewer.php?pano="+pano+"' width=480 height=270 frameborder=0 style='border:0;overflow: hidden;'></iframe>";
	document.getElementById("header").innerHTML = html;
	scroll(0,0);	
}
// Slideshow
var slideShowSpeed = 5000
var crossFadeDuration = 3
var Pic = new Array()
Pic[0] = 'upload/slideshow/arti_vegt_009.jpg'
Pic[1] = 'upload/slideshow/arti_vegt_016.jpg'
Pic[2] = 'upload/slideshow/arti_vegt_020.jpg'
Pic[3] = 'upload/slideshow/arti_vegt_024.jpg'
Pic[4] = 'upload/slideshow/arti_vegt_034.jpg'
Pic[5] = 'upload/slideshow/arti_vegt_041.jpg'
Pic[6] = 'upload/slideshow/arti_vegt_043.jpg'
Pic[7] = 'upload/slideshow/arti_vegt_047.jpg'
Pic[8] = 'upload/slideshow/arti_vegt_052.jpg'
Pic[9] = 'upload/slideshow/arti_vegt_061.jpg'
Pic[10] = 'upload/slideshow/arti_vegt_069.jpg'
Pic[11] = 'upload/slideshow/arti_vegt_076.jpg'
Pic[12] = 'upload/slideshow/arti_vegt_088.jpg'
Pic[13] = 'upload/slideshow/arti_vegt_096-2.jpg'
Pic[14] = 'upload/slideshow/artica_veg_choc.jpg'
Pic[15] = 'upload/slideshow/ChampRoll.jpg'
Pic[16] = 'upload/slideshow/Roll24nw.jpg'


var t
var j =  Math.floor(Math.random()*16)
var p = Pic.length

var preLoad = new Array()
for (i = 0; i < p; i++){
	   preLoad[i] = new Image()
	   preLoad[i].src = Pic[i]
}

function runSlideShow(){
	   if (document.all){
		  document.images.SlideShow.style.filter="blendTrans(duration=2)"
		  document.images.SlideShow.style.filter="blendTrans(duration=crossFadeDuration)"
		  document.images.SlideShow.filters.blendTrans.Apply()      
	   }
	   document.images.SlideShow.src = preLoad[j].src
	   if (document.all){
		  document.images.SlideShow.filters.blendTrans.Play()
	   }
//	   j = j + 1
//	   if (j > (p-1)) j=0

	    j = Math.floor(Math.random()*16)
	   t = setTimeout('runSlideShow()', slideShowSpeed)
}


