(function() {
	exist_forms=document.getElementsByTagName("form");
	for(gcounter=0;gcounter<exist_forms.length;gcounter++){
		f=exist_forms[gcounter];
		
		if (!f) {
		f = document.getElementById('searchbox_demo');
		}

		if (f && f.q) {
			var q = f.q;
			if(q.getAttribute("gw_apply")!=undefined && q.getAttribute("gw_apply").toLowerCase()=="true"){
				q.onfocus=function(){};
				q.onblur=function(){};
				q.style.background="";
			}else{
		
				var n = navigator;
				var l = location;
				if (n.platform == 'Win32') {
					q.style.cssText = 'background:#ffffff url(http:\x2F\x2Fwww.google.com\x2Fcoop\x2Fintl\x2Fen\x2Fimages\x2Fgoogle_custom_search_watermark.gif) left no-repeat';
				}
				var b = function() {
				if (this.value == '') {
					this.style.background = '#ffffff url(http:\x2F\x2Fwww.google.com\x2Fcoop\x2Fintl\x2Fen\x2Fimages\x2Fgoogle_custom_search_watermark.gif) left no-repeat';
				}
				};
				var f = function() {
					this.style.background = '#ffffff';
				};
				q.onfocus = f;
				q.onblur = b;
				if (!/[&?]q=[^&]/.test(l.search)) {
					b();
				}
			}
		}
	}
}
)();

