最好是jquery的<select name="select" class="frameselect" id="select">
            <option>油性皮肤</option>
            <option>干性皮肤</option>
            <option>混合性皮肤</option>
            <option>不知道</option>
          </select>
就是这种值,如何取得呢?

解决方案 »

  1.   

    js:
    var sel= document.getElementById("select");
    sel.options[sel.selectedIndex].value
      

  2.   

    document.getElementById("select").value
      

  3.   

    lz如果说text就是value的话,也可这样~
    var s=document.getElementById("select");
    s.options[s.selectedIndex].text;
      

  4.   


    <!Doctype html public '-//w3c//dtd xhtml 1.0 transitional//en' 'http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd'>
    <html xmlns='http://www.w3.org/1999/xhtml'>
    <head>
    <script language='javascript' src='js/jquery-1.3.2.js'></script>
    <script language='javascript' type='text/javascript'>
    $(document).ready(
    function()
    {
    alert($("#select").val());
    }
    );
    </script>
    </head>
    <body>
    <select name="select" class="frameselect" id="select">
                <option >油性皮肤 </option>
                <option>干性皮肤 </option>
                <option>混合性皮肤 </option>
                <option>不知道 </option>
              </select> 
    </body>
    </html>
      

  5.   

    options 即有value属性,又有text属性,要区分开<html>
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>无标题文档</title>
    <script src="js/jquery-1.3.2.min.js"></script>
    </head>
    <body>
    <select name="select" class="frameselect" id="select">
                <option value="youxing" >油性皮肤 </option>
                <option value="ganxing">干性皮肤 </option>
                <option value="hunhe">混合性皮肤 </option>
                <option value="buzhidao">不知道 </option>
              </select> 
    </body>
    </html>
    <script language="javascript">
    $(function ()
    {
     $('select').bind("change",change); 
    });
    function change(evt)
    {
    var e=window.event || evt;
    var obj=e.srcElement || e.target;
    alert("value:"+obj.value);
    alert("text:"+obj.options[obj.selectedIndex].text);
    }
    </script>