RT
请问怎么实现?谢谢

解决方案 »

  1.   


     var pub_size_type =$("#ddl_size_type").val();
        $("#ddl_size_type").change(function(){
            if(confirm(ChangeSizeTypeTip)){
              pub_size_type  = $("#ddl_size_type").val()
            }
            else{
                $("#ddl_size_type").val(pub_size_type);
            }
        });我这样写的,貌似不管用,求指点迷津
      

  2.   

    这样主要是点取消后,值变为以前的值,会继续一个Confirm确定框
      

  3.   


    $(function () {
                var pub_size_type = $("#ddl_size_type").val();
                $("#ddl_size_type").change(function () {
                    if (window.confirm("确定改变吗?")) {
                        pub_size_type = $("#ddl_size_type").val()
                    }
                    else {
                        $("#ddl_size_type").val(pub_size_type);
                    }
                });
            })