function search(strCategory) {
    /*var strUrl = "";
    if (strCategory == "video") {
        strUrl = "http://www.youtube.com/results?search_type=&aq=f&search_query=" + document.form1.sttop.value;
    }
    else if (strCategory == "audio") {
        strUrl = "http://audio.search.yahoo.com/search/audio;_ylt=?ei=UTF-8&fr=sfp&p=" + document.form1.sttop.value;
    }
	else if (strCategory == "images") {
		strUrl = "http://images.google.com/images?hl=en&btnG=Search+Images&gbv=2&q=" + document.form1.sttop.value;
	}
	else if (strCategory == "news") {
		strUrl = "http://news.google.com/news?pz=1&ned=us&hl=en&q=" + document.form1.sttop.value;
	}
    else {*/
        strUrl = "results.aspx?c=" + strCategory;
        if (document.form1.sttop.value != "")
            strUrl += "&q=" + escape(document.form1.sttop.value);
        if (document.form1.txtLayout.value != "")
            strUrl += "&l=" + document.form1.txtLayout.value;
        if (document.form1.txtToolbarID.value != "")
            strUrl += "&tid=" + document.form1.txtToolbarID.value;
        if (document.form1.txtToolbarVersion.value != "")
            strUrl += "&v=" + document.form1.txtToolbarVersion.value;
        if (document.form1.txtSource.value != "")
            strUrl += "&s=" + document.form1.txtSource.value;
    //}
    document.location.href = strUrl;
}

function setDefaultSearch(e, defaultSearch) {
    var keynum;    

    if (window.event) // IE
    {
        keynum = e.keyCode;        
    }
    else if (e.which) // Netscape/Firefox/Opera
    {
        keynum = e.which;        
    }

    if (keynum != 13) {
        //alert("Not enter key!");
        return;
    }

    document.form1.txtDefaultSearch.value = defaultSearch;
    document.form1.submit();
}

function giterDone() {
    document.form1.sttop.focus();
    document.form1.sttop.value = document.form1.sttop.value;    
}

function ToolBarInit(tool) {
    if (tool) {
        if ((document.form1) && (document.form1.txtToolbarID) && (document.form1.txtToolbarID.value == "")) {
            document.form1.txtToolbarID.value = tool.toolbarid;            
        }
    }
    //alert(document.form1.txtToolbarID.value);
}
function showMoreSearches(){
	var a = document.getElementById('related2');
	if(a){
		a.style.display = 'inline';
	}
	var b = document.getElementById('showMore');
	if(b){
		b.style.display = 'none';
	}
}

var isPushed = false;
function pushIt(btnSubmit, pressed) {    
    if (pressed == true)
    {
        isPushed = true;
    }
    if (isPushed == true) {
        btnSubmit.className = "sbutton_pushed";
    }
    return true;
}

function popIt(btnSubmit, released) {
    btnSubmit.className = "sbutton";
    if (released == true) {
        isPushed = false;
    }
    return true;
}

function findIt(box) {
    document.form1.txtDefaultSearch.value = box;
    document.form1.submit();
}