百度实现站内搜索
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
</head>
<body>
<SCRIPT language=javascript>
<!--
function go(formname)
{
var url = "http://www.baidu.com/baidu";
formname.method = "get";
if (formname.myselectvalue.value == "1") {
document.search_form1.word.value = document.search_form1.word.value+" site:hi.baidu.com/savagert";
}
formname.action = url;
return true;
}
//-->
</SCRIPT>
<form name="search_form1" target="_blank" onsubmit="return go(this)">
<input name=word size="30" value="请输入关键字" onMouseOver="this.focus()" onBlur="if (value ==''){value='请输入关键字'}" onFocus="this.select()" onClick="if(this.value=='请输入关键字')this.value=''">
<input type="submit" value="搜索"><br>
<INPUT name=myselectvalue type=hidden value=0>
<INPUT name=tn type=hidden value="sayyes">
<INPUT name=cl type=hidden value="3">
<INPUT CHECKED name=myselect onclick=javascript:this.form.myselectvalue.value=0; type=radio value=0>
<FONT color=#0000cc style="FONT-SIZE: 12px">互联网
<INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=1; type=radio value=1>
<FONT color=#ff0000 style="FONT-SIZE: 12px">站内
</form>
</body>
</html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
</head>
<body>
<SCRIPT language=javascript>
<!--
function go(formname)
{
var url = "http://www.baidu.com/baidu";
formname.method = "get";
if (formname.myselectvalue.value == "1") {
document.search_form1.word.value = document.search_form1.word.value+" site:hi.baidu.com/savagert";
}
formname.action = url;
return true;
}
//-->
</SCRIPT>
<form name="search_form1" target="_blank" onsubmit="return go(this)">
<input name=word size="30" value="请输入关键字" onMouseOver="this.focus()" onBlur="if (value ==''){value='请输入关键字'}" onFocus="this.select()" onClick="if(this.value=='请输入关键字')this.value=''">
<input type="submit" value="搜索"><br>
<INPUT name=myselectvalue type=hidden value=0>
<INPUT name=tn type=hidden value="sayyes">
<INPUT name=cl type=hidden value="3">
<INPUT CHECKED name=myselect onclick=javascript:this.form.myselectvalue.value=0; type=radio value=0>
<FONT color=#0000cc style="FONT-SIZE: 12px">互联网
<INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=1; type=radio value=1>
<FONT color=#ff0000 style="FONT-SIZE: 12px">站内
</form>
</body>
</html>