		function ancPosY(anchorPtr) 
		{
			if (document.layers) 
			{
				return anchorPtr.y;
			} 
			else if (document.getElementById || document.all) 
			{
				var pos = anchorPtr.offsetTop;
				while (anchorPtr.offsetParent != null) 
				{
					anchorPtr = anchorPtr.offsetParent;
					pos += anchorPtr.offsetTop;
				} 
				return pos;
			}
		}
		function ancPosX(anchorPtr) 
		{
			if (document.layers) 
			{
				return anchorPtr.x;
			} 
			else if (document.getElementById || document.all) 
			{
				var pos = anchorPtr.offsetLeft;
				while (anchorPtr.offsetParent != null) 
				{
					anchorPtr = anchorPtr.offsetParent;
					pos += anchorPtr.offsetLeft;
				} 
				return pos;
			}
		}

		function setCalendarPosition(anchor)
		{
			var val = ancPosX(anchor) - 80;
			if (val < anchor.clientTop)
				val = anchor.clientTop + 5;
			document.all['calendar'].style.left = val;

			val = ancPosY(anchor) - 140;
			if (val < anchor.clientLeft)
				val = anchor.clientLeft + 5;
			document.all['calendar'].style.top = val;
		}

		function getToday(date,month,year)
		{
			var today = new Date();
			if (year) today.setFullYear(today.getFullYear()+year);
			if (month) today.setMonth(today.getMonth()+month);
			if (date) today.setDate(today.getDate()+date);
			var ret = '';
			if (today.getDate() < 10)
				ret = '0';
			ret = ret + today.getDate() + '.';
			if ((today.getMonth() + 1) < 10)
				ret = ret + '0';
			ret = ret + (today.getMonth() + 1) + '.' + today.getFullYear();

			return ret;
		}


