function ChooseSearch() {
        if(document.search.searchIn[0].checked) {
         document.search.action="http://www.seed.net.tw/search/parse.php";
         SetCookie("searchtype","1",1);
        }
        if(document.search.searchIn[1].checked) {
         SetCookie("searchtype","2",1);
        }

}
function SetCookie(cookieName,cookieValue,nDays) {
 var today = new Date();
 var expire = new Date();
 if (nDays==null || nDays==0) nDays=1;
 expire.setTime(today.getTime() + 3600000*24*nDays);
 document.cookie = cookieName+"="+escape(cookieValue)
                 + ";expires="+expire.toGMTString()+ ";path=/";
}

function setValue() {
     document.search.Keywords.value=document.search.q.value;
  //   ChooseSearch();
   //  SetCookie("searchs",document.search.q.value,1);
     return true;
}
function setValue2() {
     document.search.Keywords.value=document.search.q.value;
  //   ChooseSearch();
   //  SetCookie("searchs",document.search.q.value,1);
     document.search.submit();

}

function ReadCookie(cookieName) {
 var theCookie=""+document.cookie;
 var ind=theCookie.indexOf(cookieName);
 if (ind==-1 || cookieName=="") return "";
 var ind1=theCookie.indexOf(';',ind);
 if (ind1==-1) ind1=theCookie.length;
 return unescape(theCookie.substring(ind+cookieName.length+1,ind1));
}
document.write('<form name=search action="http://www.seed.net.tw/search/search2.php" onSubmit="return setValue()">');
document.write(' <input type="hidden" name="cx" value="000438531835845153707:1psz5-kk778" /> <input type="hidden" name="cof" value="FORID:11" /> <input type="hidden" name="ie" value="UTF-8" /><input type="hidden" name=Keywords ><input type="text"  name=q class="searchInput" id="textfield3" value="請輸入關鍵字" onfocus="if(this.value==\'請輸入關鍵字\')this.value=\'\'" onblur="if(this.value==\'\')this.value=\'請輸入關鍵字\'" />');
document.write('    <a onclick="WTC(\'Seednet_home\',\'L\',\'na\',\'na\');" href="javascript:setValue2();" onmouseout="MM_swapImgRestore()" onmouseover="MM_swapImage(\'Image14\',\'\',\'/index_2009/images/search_bta.gif\' ,1)"><img src="/index_2009/images/search_bt.gif" name="Image14" width="56" height="22" border="0" align="top" id="Image14" /></a></form>');
