可選擇和輸入的下拉式清單方塊樣本

來源:互聯網
上載者:User

複製代碼 代碼如下:
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>可選擇和輸入的下拉式清單方塊</title>
<style type="text/css">
div,span,p,td,font{font-size:9pt;}
</style>
</head>
<body>

<table cellspacing="0" cellpadding="0" width="100%" border="0"><tr><td align="left">
<!--select標籤和input外面的span標籤的格式是為了使兩個位置在同一位置,控制位置-->
<span style="position:absolute;border:1pt solid #c1c1c1;overflow:hidden;width:188px;height:19px;clip:rect(-1px 190px 190px 170px);">
<select name="aabb" id="aabb" style="width:190px;height:20px;margin:-2px;"
onChange="javascript:document.getElementById('ccdd').value=document.getElementById('aabb').options[document.getElementById('aabb').selectedIndex].value;">
<!--下面的option的樣式是為了使字型為灰色,只是視覺問題,看起來像是注釋一樣-->
<option value="" style="color:#c2c2c2;">---請選擇---</option>
<option value="閑人書庫">閑人書庫</option>
<option value="閑人BLOG">閑人BLOG</option>
<option value="閑人設計">閑人設計</option>
<option value="閑人軟體">閑人軟體</option>
</select>
</span>
<span style="position:absolute;border-top:1pt solid #c1c1c1;border-left:1pt solid #c1c1c1;border-bottom:1pt solid #c1c1c1;width:170px;height:19px;">
<input type="text" name="ccdd" id="ccdd" value="可選擇也可輸入的下拉框" style="width:170px;height:15px;border:0pt;">
</span>

</td></tr></table>

</body>

</html>

注意注釋的位置。

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.