
function opacity(id, opacStart, opacEnd, millisec) {
	//speed for each frame
	var speed = Math.round(millisec / 100);
	var timer = 0;

	//determine the direction for the blending, if start and end are the same nothing happens
	if(opacStart > opacEnd) {
		for(i = opacStart; i >= opacEnd; i--) {
			setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
			timer++;
		}
	} else if(opacStart < opacEnd) {
		for(i = opacStart; i <= opacEnd; i++)
			{
			setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
			timer++;
		}
	}
}

//change the opacity for different browsers
function changeOpac(opacity, id) {
	var object = document.getElementById(id).style; 
	object.opacity = (opacity / 100);
	object.MozOpacity = (opacity / 100);
	object.KhtmlOpacity = (opacity / 100);
	object.filter = "alpha(opacity=" + opacity + ")";
}



function opacity5(id5, opacStart5, opacEnd5, millisec5) {
	if(document.getElementById(id5)){
		//speed for each frame
		var speed5 = Math.round(millisec5 / 100);
		var timer5 = 0;

		//determine the direction for the blending, if start and end are the same nothing happens
		if(opacStart5 > opacEnd5) {
			for(i5 = opacStart5; i5 >= opacEnd5; i5--) {
				setTimeout("changeOpac5(" + i5 + ",'" + id5 + "')",(timer5 * speed5));
				timer5++;
			}
		} else if(opacStart5 < opacEnd5) {
			for(i5 = opacStart5; i5 <= opacEnd5; i5++)
				{
				setTimeout("changeOpac5(" + i5 + ",'" + id5 + "')",(timer5 * speed5));
				timer5++;
			}
		}
	}
}

//change the opacity for different browsers
function changeOpac5(opacity5, id5) {
	if(document.getElementById(id5)){
		var object5 = document.getElementById(id5).style; 
		object5.opacity = (opacity5 / 100);
		object5.MozOpacity = (opacity5 / 100);
		object5.KhtmlOpacity = (opacity5 / 100);
		object5.filter = "alpha(opacity=" + opacity5 + ")";
		if(opacity5 == 0){
			object5.visibility = "hidden";
		}
	}
}




function opacity3(id3, opacStart3, opacEnd3, millisec3) {
	if(parent.document.getElementById(id3)){
		//speed for each frame
		var speed3 = Math.round(millisec3 / 100);
		var timer3 = 0;

		//determine the direction for the blending, if start and end are the same nothing happens
		if(opacStart3 > opacEnd3) {
			for(i3 = opacStart3; i3 >= opacEnd3; i3--) {
				setTimeout("changeOpac3(" + i3 + ",'" + id3 + "')",(timer3 * speed3));
				timer3++;
			}
		} else if(opacStart3 < opacEnd3) {
			for(i3 = opacStart3; i3 <= opacEnd3; i3++)
				{
				setTimeout("changeOpac3(" + i3 + ",'" + id3 + "')",(timer3 * speed3));
				timer3++;
			}
		}
	}
}

//change the opacity for different browsers
function changeOpac3(opacity3, id3) {
	if(parent.document.getElementById(id3)){
		var object3 = parent.document.getElementById(id3).style; 
		object3.opacity = (opacity3 / 100);
		object3.MozOpacity = (opacity3 / 100);
		object3.KhtmlOpacity = (opacity3 / 100);
		object3.filter = "alpha(opacity=" + opacity3 + ")";
	}
}
