function clearDiv ( divID ) {
	var divObj = document.getElementById( divID );
	if( divObj ){ divObj.innerHTML = ''; }
}

function checkFileFormat( Str ) {
	if( Str.match(/jpg/i) ){ return true; }	
	if( Str.match(/jpeg/i) ){ return true; }
	if( Str.match(/gif/i) ){ return true; }
	if( Str.match(/png/i) ){ return true; }

	return false;
}

function clearInputValue( objID ) {
	var Obj = document.getElementById( objID );
	if( Obj ){ Obj.value = ''; }
}

function showErrorMsg ( objID ) {
	var Obj = document.getElementById( objID );
	if( Obj ) { Obj.style.display = "block"; }
}

function hideErrorMsg( objIDs ) {
	var i = 0;
	while( i < hideErrorMsg.arguments.length ) {
		var Obj =  document.getElementById(hideErrorMsg.arguments[i]);
		if( Obj ){ Obj.style.display = "none"; }
		i++;
	}
}

function showObj( objID ) {
	var Obj = document.getElementById( objID );
	if( Obj.style.display == 'none' ) {
		Obj.style.display = "block";
		Obj.style.visibility = "visible";
	} else {
		Obj.style.display = "none";
		Obj.style.visibility = "hidden";
	}
}

$(document).ready(function(){
        $("#search-form-input").focus( function(){ $(this).val(""); } );
} );

