<div class="codetitle"> <span><a style="CURSOR: pointer" data="64480" class="copybut" id="copybut64480" onclick="doCopy('code64480')"><u>複製代碼</u></a></span> 代碼如下:</div> <div class="codebody" id="code64480"> <br>//W3C/1. Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <br> <br> <br><title></title> <br><!--注意引用的插件,及順序--> <br><link href="jquery.autocomplete.css" rel="stylesheet" type="text/css"> <br><script src="Jquery1.7.js" type="text/javascript"></script> <br><script src="jquery.autocomplete%20.js" type="text/javascript"></script> <br><script src="messages_cn.js" type="text/javascript"></script> <br><script type="text/javascript "> <BR>$(function () { <BR>var array = ['a', 'as', 'asd', 'bs', 'bd']; <BR>// 搜尋取得所選的值<BR>// $('#search').autocomplete(array).result(function (event, data) { <BR>// $('#Text1').val(data); <BR>// } ); <BR>//智慧型感知連線外網搜尋<BR>$('#search').autocomplete(array).result(function (event, data) { <BR>window.location.href ='http: //www.baidu.com/s?wd=' data ' &rsv_spt=1&issp=1&rsv_bp=0&ie=utf-8&tn=56060048_pg&rsv_sug3=3&rsv_sug=0&rsv_sug1=3&rsv_sug3=3&rsv_sug=0&rsv_sug1=3&rsv_sug3=3&rsv_sug=0&rsv_sug1=3&rsv_sug3=3&rsv_sug=0&rsv_sug1=3&rsv_sug3=3&rsv_sug=0&rsv_sug1=3&rsv_sug3=3&rsv_443); ></script> <br> <br> <br><div> <br><input type="text" id="search"><input type="button" id="b1" value="搜尋"><input type="text" id="Text1"> <br> </div> <br> <br> <br><br> </div>