//Set global timer variables
var timTitleDivHeight, timTitleDivWidth
var divObj, divTitle
//***********************************************************//
//This function writes the string in an element object
//both string and object`s id are parameters of the function
//***********************************************************//
function animateTitleDiv(obj, title){
	divObj = obj
	divTitle = title
	divObj.style.display = ""
	timTitleDivHeight = setInterval("animateHeight()", 1)
}
//***********************************************************//
//This function animates the box getting higher until it 
//reaches a certain size
//***********************************************************//
function animateHeight(){
	var hStep = 10
	var hLimit = 20
	if(parseInt(divObj.style.height) >= hLimit){
		clearInterval(timTitleDivHeight)
		timTitleDivWidth = setInterval("animateWidth()", 1)
		return false
	}
	hStep = parseInt(divObj.style.height) + hStep
	divObj.style.height = hStep
}
//***********************************************************//
//This function animates the box getting wider until it 
//reaches a certain size
//***********************************************************//
function animateWidth(){
	var wStep = 60
	var wLimit = 300
	if(parseInt(divObj.style.width) >= wLimit){
		clearInterval(timTitleDivWidth)
		//write title in box
		wrtThis(divObj, divTitle)
		return false
	}
	wStep = parseInt(divObj.style.width) + wStep
	divObj.style.width = wStep
}
//***********************************************************//
//This function resets all properties of the box which shows the title
//Its called on the OnMouseOut event
//***********************************************************//
function closeDiv(obj){
	obj.style.font = "normal 1px verdana"
	obj.style.width = "5"
	obj.style.height = "0"
	obj.style.display = "none"
	obj.innerHTML = ""
	clearInterval(timTitleDivWidth)
	clearInterval(timTitleDivHeight)
}
//***********************************************************//
//This function writes the string in an element object
//both string and object`s id are parameters of the function
//***********************************************************//
function wrtThis(obj, str){
	//set font size of box
	obj.style.font = "bold 8pt verdana"
	obj.innerHTML = str
}
