union.baidu.com
注册一个ID,取搜索代码即可。

解决方案 »

  1.   


    union.baidu.com
    注册一个ID,取搜索代码即可。没试过
      

  2.   

    <html>   
      <head>   
      <meta   http-equiv="Content-Type"   content="text/html;   charset=gb2312">   
      <title>无标题文档</title>   
        
      <script   language="JavaScript">   
            
        function   search4()   
      {   
        
      var   keyword,option   
        keyword   =   form2.key.value   
        option   =   form2.radio1.value   
          
      if(keyword==""){   
      alert("请填写检索关键词,将多个关键词用空格分开!")   
      return   false   
      }   
        
      if(option=='1')   
            window.open("http://search.sina.com.cn/cgi-bin/search/search.cgi?_searchkey="+keyword);   
      if(option=='2')   
            window.open("http://site.search.sohu.com/sitesearch.jsp?page_index=0&key_word="+keyword);   
      if(option=='3')   
            window.open("http://cn.search.yahoo.com/search/cn?p="+keyword);   
        if(option=='4')   
            window.open("http://www.skycn.com/search.php?sor=00&ss_name="+keyword);   
      if(option=='5')   
            window.open("http://www.google.com/search?hl=zh-CN&lr=lang_zh-CN&q="+keyword);   
      if(option=='6')   
                  window.open("http://www1.baidu.com/baidu?tn=sitehao123&word="+keyword);   
      if(option=='7')   
            window.open("http://mp3search.baidu.com/wstsearch?tn=baidump3&ct=134217728&lm=-1&rn=&word="+keyword);   
      return   false   
        }   
      </script>   
      </head>   
        
      <body>   
      <form   name="f"   method="get"   action="http://www.baidu.com/baidu">   
          <p><font   color="#FF9900"   size="+2"><strong>第一个表单输入关键字,可跳到百度该关键字搜索结果页面:</strong></font></p>   
          <p>   
              <input   name="wd"   type="text"   class="ff"   value="测试关键字"   maxlength=100>   
              <input   type="hidden"   name="cl"   value=3>   
              <input   type="submit"   name="Submit"   value="百度搜索结果">   
          </p>   
      </form>   
        
          
      <p>     
      <p>     
      <p>     
      <form   name="form2"   method="post"   action=""   onsubmit="return   search4()"   target="_blank">   
          <p><strong><font   color="#FF9900"   size="+2">第二个表单输入关键字提交后没有反应,看看源代码错在哪???</font></strong></p>   
          <p>     
              <input   name="key"   type="text"   id="key"   value="测试关键字">   
              <input   type="submit"   name="Submit2"   value="调用搜索结果!">   
          </p>   
          <p>     
                  
              <input   name="radio1"   type="radio"   value="2"   checked>   
              新浪     
              <input   type="radio"   name="radio1"   value="3">   
              搜狐     
              <input   type="radio"   name="radio1"   value="4">   
              雅虎     
              <input   type="radio"   name="radio1"   value="5">   
              软件     
      <input   name="radio1"   type="radio"   value="1">   
              Google   
              <input   type="radio"   name="radio1"   value="6">   
              百度     
              <input   type="radio"   name="radio1"   value="7">   
              MP3   </p>   
      </form>   
      </body>   
      </html>   
      

  3.   

    第二个没写action,不知道递交到哪里?