jquery attributes contol on button click
===

       <script type="text/javascript">
            $(function () {
                $('form').submit(function () {
                    $.ajax({
    
                        url: this.action,
                        type: this.method,
                        data: $(this).serialize(),
                        success: function (result) {
                            $('#popUp').html(result);
                        }
                    });
                    return false;
                });
            });
    </script>
     <script type="text/javascript">
         $(function () {
             $('form').submit(function () {
                 $("#popUp").dialog(
                 {
                    title: $(this).attr("data-dialog-title"),
                     minWidth: 500,
    
                    
                    
                 
                 );
    
             });
         });
    
    
    	</script>

The above code gave a pop up box for button click in the insert page. but How can I control the attributes of the popup box such as resizable, modal:true,false, also how can I close this popup in button click of another partial view called _error.