﻿/**

	顶部弹出广告
*/
var tm = 500;
var h = 0;
var flag = 0;
function countAdd()
{
	if(tm > 0)
	{
		tm = tm - 1;
		h = h + 5;
	}
	else return;
	
	if(h > 266) return;
	
	document.getElementById("topAd").style.display = "";
	document.getElementById("topAd").style.height = h + "px";
	document.getElementById("imageAd").style.height = h + "px";
	
	setTimeout("countAdd()", 30);
}

window.onload = function adShow()
{
	countAdd();
	showcalendar(); //	调用日期控件
	setTimeout("adNode()", 10000); 
}

var T = 266;
var N = 266; 
function adNode()
{
	if(T > 0)
	{
		T = T - 1;
		N = N - 5;
	}
	else return;
	
	if(N > 100)
	{
		document.getElementById("topAd").style.height = N + "px";
		document.getElementById("imageAd").style.height = N + "px";
	}
	else
	{
		document.getElementById("topAd").style.display="none";
		return;
	}
	setTimeout("adNode()", 30); 
}