
function checkForm( obj, str )
{				
					if ( obj.value == str ) obj.value = '';					
					
					obj.onblur=function(){
								if ( obj.value == '' ) obj.value = str;
					}
}


function autoHeight()
{		
      var objFrame = document.getElementById('iframe');
			var autoheight = objFrame.contentWindow.document.body.scrollHeight;

      objFrame.height = autoheight;
}


function randomString( strLen ) 
{
		RandStr = "";
		
		for (i = 0; i < strLen; i++) 
		{
				 RandSign = String.fromCharCode(Math.round(Math.random()*(122-48))+48);
				 if (RandSign.match(/[0-9a-zA-Z]/)) RandStr += RandSign;
				 else i--;
		}
		
		return RandStr;
}


function displayElement( obj )
{				
					$(obj).style.display = $(obj).style.display == "block" ? "none" : "block";
}


