js代码
<script type="text/javascript"> function change(){ var num1 = document.getElementById("num1").value; var num2 = document.getElementById("num2").value; { document.getElementById("num2").value = num1; document.getElementById("num1").value = num2; } } </script>