ols.util.getAbsoluteLeft = function(o) 
{	
	oLeft = o.offsetLeft            // Get left position from the parent object
	while(o.offsetParent!=null) {   // Parse the parent hierarchy up to the document element
		oParent = o.offsetParent    // Get parent object reference
		oLeft += oParent.offsetLeft // Add parent left position
		o = oParent
	}
	// Return left postion
	return oLeft
}
ols.util.getAbsoluteTop = function(o) 
{
	oTop = o.offsetTop            // Get top position from the parent object
	while(o.offsetParent!=null) { // Parse the parent hierarchy up to the document element
		oParent = o.offsetParent  // Get parent object reference
		oTop += oParent.offsetTop // Add parent top position
		o = oParent
	}
	// Return top position
	return oTop
}
ols.util.getScreenWidth = function() 
{
	if (document.all) return(document.body.clientWidth + document.body.scrollLeft)
	else return(window.innerWidth + window.scrollX)
}
ols.util.getScreenHeight = function() 
{
	if (document.all) return(document.body.clientHeight + document.body.scrollTop)
	else return(window.innerHeight + window.scrollY)
} 
ols.util.intValue = function(val)
{
	return parseInt(parseFloat(val));
}
ols.util.isIE = function(version)
{
	if(-1 != navigator.appName.indexOf('Microsoft'))
	{
		if(-1 != navigator.appVersion.indexOf('MSIE '+version))
		{
			return true;
		}
	}
	return false;
}




/**
* ===========================================================
* STRING Library START
* ===========================================================
*/
/**
* Pad a string with another string to a given length
*
* @param integer length
* @param string ch
*
* @return string
*/
String.prototype.padString = function(length, ch)
{
	var toAdd = length - this.length, pre, i;
	if(toAdd -- > 0)
	{
		for(i = 0, pre = ch; i < toAdd; i ++ )
		{
			pre += ch;
		}
		return pre + this;
	}
	return this;
};