A. 淘寶搜索框代碼
下載一個非IE內核瀏覽器(IE瀏覽器操作略麻煩),如google的chrome,然後打開別家的淘寶店鋪頁面,找到搜索欄。單擊滑鼠右鍵,選擇「審查元素(有的也叫查看源文件,查看源代碼)」,就可以看到了
B. html製作一個搜索框,代碼是什麼
1、打抄開Hbuilder編輯器,創建一個input框和button按鈕,將它們橫排擺放在一起:
C. 搜索框css樣式
<!DOCTYPEhtmlPUBLIC"-//W3C//DTDXHTML1.0Transitional//EN""
<htmlxmlns="
<head>
<metahttp-equiv="Content-Type"content="text/html;charset=utf-8"/>
<title>無標題文檔</title>
<scripttype="text/javascript"src="jquery.js"></script>
<style>
.{padding:0;margin:0;list-style:none;}
.htmlBox{width:100%;min-width:500px;height:500px;border:1pxsolid#A349A4;border-radius:5px;}
.sskBox{width:100%;height:35px;margin-top:150px;border:1pxsolid#000;border-left:0;border-right:0;}
.zc{width:100px;height:35px;float:left;}
.zj{width:250px;height:35px;float:left;border-left:1pxsolid#000;border-right:1pxsolid#000;}
.yc{height:35px;float:right;}
</style>
</head>
<body>
<divclass="htmlBox">
<divclass="sskBox">
<divclass="zc">左邊100</div>
<divclass="zj">中間250</div>
<divclass="yc">右邊自適應</div>
</div>
</div>
</body>
<script>
tmntH();//載入的時候執行一次
$(window).resize(function(){tmntH();});//瀏覽器窗口變化時執行
functiontmntH()
{
varycw=$(".sskBox").width()-352+'px';//yc的寬度等於sskBox寬度-350-2(邊框線)
//alert(div3);
$(".yc").css("width",ycw);
}
</script>
</body>
</html>
D. html製作一個搜索框,代碼是什麼
html製作一個搜索框,代碼是:testvarNS4=(document.layers);//Whichbrowser?
E. html搜索欄代碼
<style>
.button{border:2pxsolid#C5C5C5;background:#EEEEEE;margin:04px;}
.search{border:2pxsolid#C5c5c5;}
</style>
<divclass="searchdiv">
<inputtype="text"class="search"/>
<inputtype="button"value="搜索抄"class="button"/>
<inputtype="button"value="高級"class="button"/>
</div>
我用純html 做的 如果你用了圖片按鈕 可以試一試給.search和.button 加上vertical-align:middle;這個屬性
F. html搜索框代碼怎樣寫
可以使用<form>標簽
比如經典的網路搜索框
<form action="http://www..com/" ><input name="word" type="search" /><input type="submit" value="網路搜索" /></form>
更多可以去學習表單網頁鏈接
G. js搜索框代碼
/*問題不夠明確*/
<inputclass="ipt_search"type="search"placeholder="請輸入搜索內容"/>
<script>
/*搜索input*/
varsearchIpt=document.getElementsByClassName('ipt_search')[0];
/*搜索內容*/
varsearchValue=searchIpt.value;
</script>
H. html中搜索框怎麼做
<inputtype="text"class="aa"><inputtype="button"value="搜索"class="bb">
I. 淘寶搜索框自定義代碼
<!--
·1此代碼默認尺寸200x30像素(文本框:170x30像素;提交按鈕:30x30像素);
·2代碼僅為框架,可通過使用內聯樣式添加背景圖片實現效果;
·3如需使用border屬性添加邊框,請勿刪除之前的border樣式,並且要減去相應的高寬數值
-->
<!--搜索代碼-->
<formaction="#店鋪搜索頁鏈接"method="get"target="_blank"style="width:200px;height:30px;border:0;padding:0;outline:none;">
<!--搜索按鈕-->
<inputname="search"type="submit"value=""style="width:30px;height:30px;background-color:#C9C9C9;border:0;padding:0;outline:none;cursor:pointer;float:right;">
<!--搜索按鈕End-->
<!--文本輸入-->
<inputname="keyword"type="text"value=""style="width:170px;height:30px;background-color:#E5E5E5;border:0;padding:0;outline:none;text-indent:5px;cursor:text;float:left;">
<!--文本輸入End-->
</form>
<!--搜索代碼End-->
回答中無法添加具體鏈接,代碼中 「#店鋪搜索頁鏈接」即為打開店鋪搜索頁,地址欄內的地址鏈接,可只保留到search.htm位置
具體操作可讀注釋,更多問題可追問或私信
具體效果可搜索瀏覽 「盈兆電器專營店」
滿意請隨手 點贊 支持 (๑•̀ㅂ•́)و✧
J. 怎麼寫搜索框中的代碼啊
首先把搜索寬切片下來再CSS樣式裡面用為背景
<body>
<form action="" method="get">
<div class="kuan"><input name="" type="text" /></div><!--搜索框-->
<div class="an"><input name="" type="button" /></div><!--搜索按鈕版-->
</form>
</body>
CSS樣式根據實際權自己調整
<style type="text/css">
.kuan input{ width:330px; height:60px; background:background:url(../img/kuan_01.jpg) no-repeat; border:none; float:left}
.an input{ width:120px; height:60px; background:background:url(../img/an_02.jpg) no-repeat;border:none; float:left}
</style>