• java script两个列表之间移动数据


    <select name="b1" id="hao" style="100px; height:200px;" size="8">
            <option>左1  </option>
            <option>  左2</option>
            <option >  左3</option>
        </select>
        <input  type="button" name="xiangzuo" id="zuo" value="》" onclick="zuo()" size="8"/>
        <input  type="button" name="xiangyou" id="you" value="《"/ onclick="you()" size="8"/>
        <select name="b2" id="buhao" style="100px; height:200px;" size="8">
            <option >右1  </option>
            <option >  右2</option>
            <option>  右3</option>
        </select>
        <script>
            function zuo()
            {
                var op=document.getElementById("hao").selectedOptions;
                
                document.getElementById("buhao").appendChild(op[0]);
                document.getElementById("hao").removeChild(op[0]);
                
            }
        function you(){
            var op=document.getElementById("buhao").selectedOptions;
            document.getElementById("hao").appendChild(op[0]);
            document.getElementById("buhao").removeChild(op[0]);
            }
        </script>

  • 相关阅读:
    K-Multiple Free set UVA-11246 (容斥原理)
    RAID! UVA-509 (奇偶校验)
    龙芯 fedora28 安装指南
    Kdenlive简明教程-简单的操作
    Kdenlive简明教程-开始
    Irrelevant Elements UVA-1635 (二项式定理)
    指针的指针笔记
    scanf 函数笔记
    printf 函数笔记
    龙芯 3A4000 Fedora28 安装笔记
  • 原文地址:https://www.cnblogs.com/yi11/p/6611092.html
Copyright © 2020-2023  润新知