/ Published in: ASP
in form elements,select unit make user more choice and flexiable. if can seal all the code in a function, that will be helpful for the coder
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
<style> .float_typeid { float:left; margin-right:6px; } .float_typeid select { float:left; height:20px; } .float_typeid a { background:#FFFFFF url(../../images/default/newarow.gif) no-repeat scroll 100% 0pt; border-color:#999999 rgb(204, 204, 204) rgb(204, 204, 204) rgb(153, 153, 153); border-style:solid; border-width:1px; color:#444444 !important; display:block; height:20px; overflow:hidden; padding-right:17px; text-decoration:none !important; text-indent:4px; width:77px; } .float_typeid a:hover { background-position:100% -20px; border:1px solid #009B97; text-decoration:none; } </style> <div class="float_typeid"> <select style="width: 94px; display: none;" selecti="2" name="typeid" id="typeid"> <option value="17"></option> </select> <a tabindex="1" onclick="loadselect_viewmenu(this, 'typeid', 0, 'floatlayout_newthread');doane(event)" onkeyup="loadselect_key(this, event, 'typeid', 'floatlayout_newthread')" onmouseout="this.blur()" onmouseover="this.focus()" onblur="loadselect_keyinit(event, 2)" onfocus="loadselect_keyinit(event, 1)" id="typeid_selectinput" class="loadselect" href="javascript:;">�¦ï¿½�°�¦ï¿½�®</a> <ul style="z-index: 999; position: absolute; width: 94px; display: none;" id="typeid_selectmenu" class="newselect" onblur="loadselect_keyinit(event, 2)" onfocus="loadselect_keyinit(event, 1)"> <li onclick="loadselect_liset('typeid', 0, 'typeid','15',this.innerHTML, 0)" k_value="15" k_id="typeid" class="">item1</li> <li onclick="loadselect_liset('typeid', 0, 'typeid','16',this.innerHTML, 1)" k_value="16" k_id="typeid">item2</li> <li onclick="loadselect_liset('typeid', 0, 'typeid','17',this.innerHTML, 2)" k_value="17" k_id="typeid" class="current">item3</li> <li onclick="loadselect_liset('typeid', 0, 'typeid','25',this.innerHTML, 3)" k_value="25" k_id="typeid">item4</li> <li onclick="loadselect_liset('typeid', 0, 'typeid','19',this.innerHTML, 4)" k_value="19" k_id="typeid">item5</li> <li onclick="loadselect_liset('typeid', 0, 'typeid','18',this.innerHTML, 5)" k_value="18" k_id="typeid">item6</li> </ul> </div>