	//script regarding to the search engine called widget search where we had google custom search imageto be hidden on click on textbox
	//Author Nahida Bashir Dated:04-01-2011 4:41 pm
	function loadhtml()
	{ 
		//value variable stores all the data coming from above state 
		var value='<div id="google-search"><form method="get" action="http://www.greenmaven.com/" id="searchbox_004519335225175341333:qqryuvkxnvm" target="_blank">';
		//this div is for external image to get displayed(outermost) 
		value =  value +'<div id="search-inside">';
		// division for the outer textbox in which magnifier and search box is located (it is actually an image)
		value =  value +'<div id="text-box">';
		//this division has the style for margining the image given in <div id="text-box"> above
		//it also includes a textbox for entering searching data which searches on the basis of google search
		//there is a feature for in the below input it calls two fuctions onfocus and onblur
		//onfocus leads the gogle custom image to get hidden
		//on blur helps in recollecting it
		value =  value +'<div id="search_box"><input type="text" class="bigtext" id="gsearchbox1" name="q"  onfocus="fntxtOnFocus(this)" onblur="fntxtOnBlur(this)"/>';
		//the below given input includes the hidden textbox which will get a value to be stored in for searching value in greenmaven site
		value =  value + '<input type="hidden" value="com_googlesearch" name="option" /> <input type="hidden" value="004519335225175341333:qqryuvkxnvm" name="cx"/>';
     	//closing the nearest div
		value =  value +'</div>';
		//below division is for magnifier to be  set consists of its css properties
		//it will also reflect the search value in greenmaven site
		value =  value +'<div id="magnifier">';
		value =  value +'<input  name="magnifier" id="magnifier" type="image" src="http://www.greenmaven.com/widgetsearch/images/magnifier_150px.png" name="sa"/></div>';
		value =  value +'</div>';
		//closing nearest div
		// submit buttton for searching value of the textbox in greenmaven
		//it helps in searching by storing data of textbox in hidden fields and extracting in greenmaven 
		value =  value +'<div id="submit-btn">';
		value =  value +'<input  name="Submit" id="submit-btn"type="image" src="http://www.greenmaven.com/widgetsearch/images/1greenbutton.png" name="sa"/></div>';
		value =  value +'<input type="hidden" value="FORID:9" name="cof"/>'; 
		value =  value +'<input type="hidden" value="48" name="Itemid"/>';
		value =  value +'<input type="hidden" value="'+location.host+'" name="utm_source"/>';
		value =  value +'<input type="hidden" value="yes" name="gsearch"/>'; 
		value =  value +'<input type="hidden" value="widgets" name="utm_medium"/>'; 
		value =  value +'<input type="hidden" value="GreenSearch" name="utm_campaign"/>'; 
		//helps in reflecting poweredby option 
		value =  value +'<div class="poweredby"><a href="http://www.greenmaven.com">Powered by Green Maven</a></div>'
		value =  value+'</div>';
		value =  value+'</form></div>';
		
		document.getElementById('cse').innerHTML= value;
	}
function fntxtOnFocus(q)
{  
if (q.value == ''){ q.style.backgroundImage = "none"; }
}

function fntxtOnBlur(q)
{
	
if (q.value == "") { q.style.backgroundImage = "url(http://www.greenmaven.com/widgetsearch/images/bg-google-custom-search.png)";}
}

	 

