select控件的左边有个小三角,点击一下就能弹出列表框(options)来.有什么办法不用点击小三角也能弹出那个列表框来?

解决方案 »

  1.   


    左边?你是说右边吧。
    select本来不就是做这个吗?
    向select中加入option就可以了。
      

  2.   

    <SELECT size=2 id=select1 name=select1>
    <OPTION>列表框</OPTION>
    </SELECT><SELECT size=1 id=select1 name=select1>
    <OPTION>下拉框</OPTION>
    </SELECT>
      

  3.   

    什么弹出列表框? select本身不就是有列表吗?  你弹什么啊..你的意思是想动态生成一个select列表?还是?
    你得说清楚需求啊
      

  4.   

    我有一个select和一个text,我在text内输入值,同时select要把带有该值的项显示出来(也就是一个搜索的功能),可我不知道怎么才能使select自动弹出选择项来.想问的就是,除了点三角能弹出选项,还有什么方法能起到同样的效果?
      

  5.   


    <select id="s1">
    <option>123</option>
    <option>456</option>
    <option>789</option>
    <option>abc</option>
    <option>def</option>
    </select>
    <INPUT TYPE="button" VALUE="显示" ONCLICK="var s1=document.getElementById('s1');s1.size=s1.options.length">
      

  6.   


    <script>
    function search(value)
    {
    var arr=["1","2","3","4"];
    var result=new Array;
    var oSel=document.getElementById("s1");
    if(value=='')
    {
    oSel.options.length=0;
    return;
    }
    for(var i=0;i<arr.length;i++)
    {
    if(arr[i].indexOf(value)!=-1)
    {
    result.push(arr[i]);
    }
    }
    oSel.options.length=0;
    for(var i=0;i<result.length;i++)
    {
    oSel.options.add(new Option(result[i],result[i]));
    }
    }
    </script>
    <input type="text" onkeyup="search(this.value)"><br>
    <select id="s1" style="width:150;height:100;" multiple="multiple">
    </select>
      

  7.   

    问题虽没解决,谢谢大家的热心,分给最热心的neo_yoho