HTML中搜索框怎么做

如图标签写详细一点谢谢... 如图标签写详细一点谢谢 展开
 我来答
cc8hack
2017-09-25 · 超过37用户采纳过TA的回答
知道小有建树答主
回答量:211
采纳率:0%
帮助的人:83.6万
展开全部
以下是百度的搜索引擎的

<form onsubmit="return gowhere1(this)" target="_blank" name="search_form1" method="get" action="http://www.baidu.com/baidu">
<table width="100%" height="80" cellspacing="0" cellpadding="0" border="0" style="font-family:宋体">
<tbody>
<tr>
<td>
<table width="144%" height="80" cellspacing="0" cellpadding="0" border="0">
<input type="hidden" value="0" name="myselectvalue">
<input type="hidden" value="utf-8" name="ie">
<input type="hidden" name="tn" value="SE_zzsearchcode_shhzc78w">
<input type="hidden" name="ct">
<input type="hidden" name="lm">
<input type="hidden" name="cl">
<input type="hidden" name="rn">
<tbody>
<tr>
<td width="8%" valign="bottom">
<div align="center">
<a href="https://www.baidu.com/" target="_blank">
<img border="0" align="bottom" alt="Baidu" src="https://www.baidu.com/img/baidu_jgylogo3.gif">
</a>
</div>
</td>
<td width="92%" valign="bottom">

<input type="radio" value="0" onclick="javascript:this.form.myselectvalue.value=4;" name="myselect">
<font color="#0000cc">新闻</font>

<input type="radio" value="0" onclick="javascript:this.form.myselectvalue.value=0;" name="myselect" checked="">
<span class="f12"><font color="#0000cc">网页</font></span>

<input type="radio" value="1" onclick="javascript:this.form.myselectvalue.value=1;" name="myselect">
<span class="f12"><font color="#0000cc">音乐</font></span>

<input type="radio" value="0" onclick="javascript:this.form.myselectvalue.value=6;" name="myselect">
<font color="#0000cc">贴吧</font>

<input type="radio" value="0" onclick="javascript:this.form.myselectvalue.value=5;" name="myselect">
<font color="#0000cc">图片</font>

<table width="100%" cellspacing="0" cellpadding="0" border="0" align="right">
<tbody>
<tr>
<td style="padding-top:10px;">
<font>
<input id="word" type="text" name="word" size="40" onfocus="checkHttps">
</font>
<input type="submit" value="百度一下">
</td>
<td><br></td>
</tr>
</tbody>
</table>
</td>
</tr>
<tr>
<td width="8%"></td>
<td width="92%"></td>
</tr>
<tr><td></td></tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</form>
<script src="http://s1.bdstatic.com/r/www/cache/global/js/BaiduHttps_20150714_zhanzhang.js"></script>
<script>
function checkHttps () {
BaiduHttps.useHttps();
};
function gowhere1 (formname) {
var data = BaiduHttps.useHttps();
var url;
if (formname.myselectvalue.value == "0") {
url = data.s == 0 ? "http://www.baidu.com/baidu" : 'https://www.baidu.com/baidu' + '?ssl_s=1&ssl_c' + data.ssl_code;
document.search_form1.tn.value = "SE_zzsearchcode_shhzc78w";
formname.method = "get";
}
if (formname.myselectvalue.value == "1") {
document.search_form1.tn.value = "SE_zzsearchcode_shhzc78w";
document.search_form1.ct.value = "134217728";
document.search_form1.lm.value = "-1";
url = "http://mp3.baidu.com/m";
}
if (formname.myselectvalue.value == "4") {
document.search_form1.tn.value = "SE_zzsearchcode_shhzc78w";
document.search_form1.cl.value = "2";
document.search_form1.rn.value = "20";
url = "http://news.baidu.com/ns";
}
if (formname.myselectvalue.value == "5") {
document.search_form1.tn.value = "SE_zzsearchcode_shhzc78w";
document.search_form1.ct.value = "201326592";
document.search_form1.cl.value = "2";
document.search_form1.lm.value = "-1";
url = "http://image.baidu.com/i";
}
if (formname.myselectvalue.value == "6") {
document.search_form1.tn.value = "SE_zzsearchcode_shhzc78w";
document.search_form1.ct.value = "352321536";
document.search_form1.rn.value = "10";
document.search_form1.lm.value = "65536";
url = "http://tieba.baidu.com";
}
formname.action = url;
return true;
}
</script>
本回答被提问者和网友采纳
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式