`
zjjzmw1
  • 浏览: 1366531 次
  • 性别: Icon_minigender_1
  • 来自: 开封
社区版块
存档分类
最新评论

百度google搜索嵌入

 
阅读更多

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html><head><title>搜狗网址导航</title><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /><meta http-equiv="Content-Type" content="text/html;charset=utf-8"><meta name="keywords" content="123,网址导航" />
   
    <SCRIPT language=javascript>
        function gowhere1(formname)
        {
            var url;
            <!--新闻-->
            if (formname.myselectvalue.value == "1")
            {
                document.search_form1.tn.value = "news";
                document.search_form1.cl.value = "2";
                document.search_form1.rn.value = "20";
                document.search_form1.ie.value = "utf-8";
                url = "http://news.baidu.com/ns";
            }
            <!--网页-->
            if (formname.myselectvalue.value == "0")
            {
                url = "http://www.baidu.com/baidu";
                document.search_form1.tn.value = "baidu";
                formname.method = "get";
            }
            <!--贴吧-->
            if (formname.myselectvalue.value == "2")
            {
                document.search_form1.ie.value = "utf-8";
                document.search_form1.kw.value = document.getElementById("word").innerHTML;
                    url = "http://tieba.baidu.com";
            }
            <!--知道-->
            if (formname.myselectvalue.value == "3")
            {
                document.search_form1.pn.value = "0";
                document.search_form1.rn.value = "10";
               
                document.search_form1.word.value = document.getElementById("word").innerHTML;
                document.search_form1.lm.value = "0";
                url = "http://zhidao.baidu.com/search";
            }
            <!--音乐-->
            if (formname.myselectvalue.value == "4")
            {
                url = "http://mp3.baidu.com/m";
                document.search_form1.tn.value = "baidump3";
                document.search_form1.ct.value = "134217728";
                document.search_form1.lm.value = "-1";
                document.search_form1.ie.value = "utf-8";
            } 
            <!--图片-->
            if (formname.myselectvalue.value == "5")
            {
                document.search_form1.tn.value = "baiduiamge";
                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.ct.value = "301989888";
                document.search_form1.ie.value = "utf-8";
                document.search_form1.s.value = "25";
                document.search_form1.word.value = document.getElementById("word").innerHTML;
               
                url = "http://v.baidu.com/v";
            }
            <!--地图-->
            if (formname.myselectvalue.value == "7")
            {
                document.search_form1.newmap.value = "1";
                document.search_form1.ie.value = "utf-8";
                document.search_form1.s.value = "s%26wd%3D"+document.getElementById("word").innerHTML;
                url = "http://map.baidu.com/";
            }
           
            <!--百科-->
            if (formname.myselectvalue.value == "8")
            {
   
                document.search_form1.ie.value = "utf-8";
           
                document.search_form1.word.value = document.getElementById("word").innerHTML;
               
                url = "http://baike.baidu.com/";
            }
            <!--文库-->
            if (formname.myselectvalue.value == "9")
            {
      
                document.search_form1.ie.value = "utf-8";

                document.search_form1.word.value = document.getElementById("word").innerHTML;
               
                url = "http://wenku.baidu.com/search";
            }
            formname.action = url;
            return true;
        }
        </SCRIPT>
</head>
    <body>
        <form name="search_form1" target="_blank" onsubmit="return gowhere1(this)" align=center>
            <table width="920" height="60" border="0" bgcolor="#FFFFFF" cellpadding="0" cellspacing="0" style=font-family:宋体 ><tr><td>
                <TABLE width="920" height="80" border=0 cellPadding=0 cellSpacing=0 >
                    <INPUT name=myselectvalue type=hidden value=0>
                        <INPUT name=tn type=hidden>
                            <INPUT name=ct type=hidden>
                                <INPUT name=lm type=hidden>
                                    <INPUT name=cl type=hidden>
                                        <INPUT name=rn type=hidden>
                                            <INPUT name=kw type=hidden>
                                                <INPUT name=word type=hidden>
                                                    <INPUT name=pn type=hidden>
                                                        <INPUT name=newmap type=hidden>
                                                        <INPUT name=s type=hidden>
                                                        <INPUT name=ie type=hidden>
                                                            <TR>
                                                                <TD width="8%" valign="center">
                                                                    <DIV align=center><a href="http://www.baidu.com/"><img src="http://www.baidu.com/img/bdlogo.gif"
                                                                        alt="Baidu" align="bottom" border="0"></a></DIV></TD>
                                                                <TD vAlign=bottom width="92%">
                                                                    <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=1; type=radio value=0 >
                                                                        <FONT color=#0000cc style="FONT-SIZE: 12px">新闻</FONT>
                                                                       
                                                                        <INPUT CHECKED name=myselect onclick=javascript:this.form.myselectvalue.value=0; type=radio value=0>
                                                                            <SPAN class=f12><FONT color=#0000cc style="FONT-SIZE: 12px">网页</FONT></SPAN>
                                                                            <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=2; type=radio value=1>
                                                                                <SPAN class=f12><FONT color=#0000cc style="FONT-SIZE: 12px">贴吧</FONT></SPAN>
                                                                                <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=3; type=radio value=0>
                                                                                    <FONT color=#0000cc style="FONT-SIZE: 12px">知道</FONT>
                                                                                    <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=4; type=radio value=0>
                                                                                        <FONT color=#0000cc style="FONT-SIZE: 12px">音乐</FONT>
                                                                                        <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=5; type=radio value=0>
                                                                                            <FONT color=#0000cc style="FONT-SIZE: 12px">图片</FONT>
                                                                                           
                                                                                            <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=6; type=radio value=0>
                                                                                                <FONT color=#0000cc style="FONT-SIZE: 12px">视频</FONT>
                                                                                           
                                                                                                <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=7; type=radio value=0>
                                                                                                    <FONT color=#0000cc style="FONT-SIZE: 12px">地图</FONT>
                                                                                               
                                                                                                    <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=8; type=radio value=0>
                                                                                                        <FONT color=#0000cc style="FONT-SIZE: 12px">百科</FONT>
                                                                                                        <INPUT name=myselect onclick=javascript:this.form.myselectvalue.value=9; type=radio value=0>
                                                                                                            <FONT color=#0000cc style="FONT-SIZE: 12px">文库</FONT>
                                                                                                   
                                                                                            <TABLE align=right border=0 cellPadding=0 cellSpacing=0 width="100%" >
                                                                                               
                                                                                                <TBODY>
                                                                                                    <TR>
                                                                                                        <TD><FONT style="FONT-SIZE: 12px">
                                                                                                            <input id="word" name=word size="45">
                                                                                                               
                                                                                                                </FONT> <input type="submit" value="百度搜索"> </TD></TR>
                                                                                                   
                                                                                                    </form>
        <!-- 准备通过程序动态添加提示功能的input  -->
        <span id="alertSpan" ></span>
       
       
       
        <!-- google search  -->
       
        <form action="http://www.google.com/search"   name=f align=center>
            <span   id=hf></span>
            <table   cellspacing=0   cellpadding=0 width="920">
                <tr   valign=middle>
                    <TD width="8%" valign="left">
                        <DIV align=center><a href="http://www.google.com/search"><img src="http://a4.att.hudong.com/56/94/01300000674874127805943299457.jpg"
                            alt="Baidu" align="bottom" border="0"></a></DIV></TD>
                    <td   align=left>
                        <input   maxLength=256   size=45   name=q   value="" id="gugou">  
                            <script>  
                                document.f.q.focus();  
                                </script>  
                            <input   type=hidden   name=ie   value="UTF-8">
                                <input   type=hidden   name=oe   value="UTF-8">
                                    <input   name=hl   type=hidden   value=zh-CN>
                                        <input   type=submit   value="Google搜索" >
                                            </td>
                </tr>
            </table>
        </form>
       
    </body>
   
    <!-- 百度搜索框提示 -->
    <script charset="gbk" src="http://www.baidu.com/js/opensug.js"></script>
   
    <!-- 程序示例  -->
   
    <script type="text/javascript">
        var txtObj = document.getElementById("alertSpan");
       
        //回调函数,用于获取用户当前选择的文字
        function show(str){
            <!--txtObj.innerHTML = str;-->
        }
       
        var params = {
            "XOffset":0, //提示框位置横向偏移量,单位px
            "YOffset":0, //提示框位置纵向偏移量,单位px
            "width":204, //提示框宽度,单位px
            "fontColor":"#f70", //提示框文字颜色
            "fontColorHI":"#FFF",    //提示框高亮选择时文字颜色
            "fontSize":"13px",        //文字大小
            "fontFamily":"宋体",    //文字字体
            "borderColor":"gray",     //提示框的边框颜色
            "bgcolorHI":"#03c",        //提示框高亮选择的颜色
            "sugSubmit":false        //在选择提示词条是是否提交表单
        };
       
        BaiduSuggestion.bind("word",params,show);
        BaiduSuggestion.bind("gugou",params,show);
        </script>
</html>





























分享到:
评论

相关推荐

    MFC 嵌入百度谷歌搜索源码

    这个“MFC 嵌入百度谷歌搜索源码”项目涉及了如何在MFC对话框中集成网络搜索功能,让用户可以直接在应用内部进行搜索,无需离开程序。下面将详细介绍这一知识点,以及相关的编程技术和实现步骤。 首先,我们要理解...

    用php+ajax写的仿百度谷歌搜索下拉自动提示框效果

    这个项目“用php+ajax写的仿百度谷歌搜索下拉自动提示框效果”旨在实现类似百度和谷歌搜索引擎的实时搜索建议功能。下面我们将详细探讨这个过程涉及的关键知识点。 首先,我们要理解**PHP**(Hypertext ...

    在自己的网页里套上百度搜索引擎,谷歌搜索引擎,文本框中输入文字会显示下拉提示自动补全文字,点百度一下打开百度显示你搜索的文字.zip

    对于谷歌搜索引擎的集成,"百度首页和搜索页面添加 Google 搜索框 - Lähdekoodi.url" 可能是一个链接,指向Google搜索框的源代码或教程。谷歌的搜索框可以通过嵌入一个iframe来实现,iframe的src属性指向Google的...

    百度地图搜索功能的实现

    1. **百度地图API**:百度地图提供了丰富的JavaScript API,允许开发者在网页上嵌入地图,实现各种地图相关的功能。使用百度地图API,我们可以获取地图数据,设置地图中心点,缩放级别,以及添加标记、热力图等元素...

    idea百度搜索Ideasearchwithbaidui.zip

    这个压缩包包含的项目是为了解决在国内使用IntelliJ IDEA时,由于Google搜索服务可能受限而带来的不便。描述指出,通过安装特定的插件ideat1.jar,用户可以在IDEA中添加百度搜索选项,从而实现更顺畅的开发环境体验...

    phpsearch用php+ajax仿百度谷歌搜索下拉效果.zip

    本项目"phpsearch用php+ajax仿百度谷歌搜索下拉效果"旨在模仿这两个巨头的搜索框下拉建议功能,它能根据用户输入的关键词实时提供相关的搜索建议,大大提升了搜索效率。下面我们将详细探讨这个项目涉及到的技术和...

    PHP实例开发源码-哥博客百度谷歌搜索系统php版.zip

    【PHP实例开发源码-哥博客百度谷歌搜索系统php版.zip】是一个PHP开发的源代码包,主要用于构建一个集成了百度和谷歌搜索功能的系统。这个项目可能旨在帮助用户在自己的网站上实现对这两个搜索引擎的集成,从而方便地...

    搜索引擎盈利模式探析——以百度和Google为例.docx

    本文将深入探讨以百度和Google为代表的搜索引擎公司的主要盈利模式。 首先,我们关注的是百度。作为中国最大的搜索引擎,百度的主要盈利途径是其广告平台——百度推广。百度推广基于关键词竞价排名机制,企业或个人...

    搜索排名点击百度,谷歌,搜搜

    在互联网营销领域,搜索排名点击是一个关键的概念,它涉及到如何提升网站在搜索引擎结果页面(SERP)中的位置,特别是对于百度、谷歌和搜搜(已并入腾讯搜狗)这三大主流搜索引擎。本文将深入探讨搜索排名点击的重要...

    搜索引擎广告嵌入赚钱

    2. **选择合适的搜索引擎**:目前市场上主流的搜索引擎包括谷歌(Google)、百度、360搜索等。不同的搜索引擎可能有着不同的用户群体特征,因此选择合适的搜索引擎对于提高广告效果至关重要。 3. **注册并创建广告...

    基于PHP的百度和google搜索引擎源代码PHP版.zip

    标题中的“基于PHP的百度和google搜索引擎源代码PHP版.zip”揭示了这个压缩包内容的中心主题,即一套使用PHP编程语言实现的百度和Google搜索引擎的源代码。PHP是一种广泛用于Web开发的开源脚本语言,它允许开发者在...

    谷歌百度地图调用

    谷歌地图API是一个强大的工具,允许开发者在网页上嵌入交互式地图,进行位置搜索,导航,甚至包括路线规划等。在`google.html`文件中,你可能会看到以下基础的谷歌地图初始化代码: ```html &lt;!DOCTYPE html&gt; ...

    李彦宏-贴吧推出后百度谷歌技术上已分道扬镳.docx

    2021年,百度进一步推出了应用开放平台,允许各种应用程序嵌入到搜索结果中,用户可以直接在搜索结果页面上进行交互,如玩游戏、使用计算器、听音乐等,无需跳转至其他网站。这种创新模式被西方媒体视为百度与谷歌在...

    Java_百度地图_搜索附近美食

    这可能需要用到百度地图的JavaScript API,通过嵌入网页的方式在Java Swing或JavaFX应用中展示地图。 7. **多线程与异步处理**:考虑到网络请求可能耗时,为了提升用户体验,可以采用多线程或异步处理方式,避免...

    百度,谷歌,天气预报API应用实例

    接下来是谷歌API,谷歌也提供了广泛的服务,包括谷歌地图API、谷歌翻译API、谷歌搜索API等。以谷歌地图API为例,它可以帮助开发者在网页上展示动态地图,提供地理编码、路线规划等功能。同样,使用谷歌API也需要注册...

    百歌搜索引擎tomcat嵌入版(Baioogle-SearchEngine Embed in Tomcat)

    3.接下来的操作就和使用百度、谷歌类似了。 注:可以进入“...\Baioogle-SearchEngine Embed in Tomcat\apache-tomcat-5.5.28-embed\webapps\Root\cache”目录,执行里面的bat文件爬取感兴趣的网站,之后再建立...

    编BHO截获并替换_百度、谷歌搜索表单

    文章还提到编写BHO来截获并替换百度、谷歌等搜索引擎的搜索表单。实现这一功能,程序员需要编写代码来监听浏览器事件,然后在适当的时机替换掉原有的表单,插入自定义的表单。这样,用户在使用搜索引擎时会发送请求...

    JSP+Ajax+Servlet 自动完成类似谷歌百度搜索

    本项目是关于构建一个使用JSP、Ajax和Servlet技术实现的自动完成搜索功能,类似于谷歌或百度搜索引擎的用户体验。这个功能在用户输入关键字时,后台会实时查询数据库并返回相关的建议搜索词,提高了搜索效率和用户...

    EPSON推广方案 百度谷歌引擎优化seo学习资料

    描述中的“百度谷歌引擎优化”提到了两个主要的搜索引擎——百度和谷歌。百度是中国最大的搜索引擎,而谷歌则是全球范围内的主导者。对这两个平台进行优化是提升企业网站流量的关键。SEO的学习资料通常会涵盖关键词...

Global site tag (gtag.js) - Google Analytics