/**
 * @author Volker
 */
window.onload = function(){
	initPage();
};

function initPage(){
	ImixsHomePage.attachClearSearch();
	// temporär bis Suche eingebaut
	if (document.forms[0]){
/*
		document.forms[0].onsubmit = function(){
			alert('Suche noch nicht implementiert');
			return true;
		};
*/
	}
}

ImixsHomePage = {
	// fields
	sInitialSearchValue : '',
	// methods
	attachClearSearch : function(){
		var el = document.getElementById('Query');
		if(el){
			this.sInitialSearchValue = el.value;
			el.onfocus = function(){
				if(this.value == ImixsHomePage.sInitialSearchValue){
					this.value = '';
				}
			};
			el.onblur = function(){
				if(this.value === ''){
					this.value = ImixsHomePage.sInitialSearchValue;
				}
			};
		}
	}
};
