function onText(str){ window.status = str; return true }
function offText(){ window.status = ""; return true }

function isNull(s) { return ((s == null) || (s == "")); }
// Function checks whether the passed string has all printable characters.
// checks if the string contains all characters that satisfy isprint() of Standard C library fn.
function isPrintable(s) 
{
	if(s.search(/[^\x20-\x7e]/)!=-1) return false;
	return true;
}
// function to check that the subject is not composed of only spaces. 
// Will return false if the string is composed of all spaces. 
// Moreshwar 29th December, 2004. 
function trimWhiteSpace (str)
{
	// serach and remove trailing and staring blank spaces. 
	str = str.replace(/^[\s]+/,"").replace(/[\s]+$/,"");
	return str;		
}

// function to limit the maximum length of the text box. 
// Moreshwar 29th December, 2004. 
function textLimit(field, maxlen) 
{
	// make sure that the last char added is also truncated.
	// No alerts have been provided.
	if (field.value.length >= maxlen)
		field.value = field.value.substring(0, maxlen);
}

// Angrez: 19-1-2006:
// Function to check if URL is escaped or not
function isEscaped(url)
{
    return url != unescape(url);
}