Dialog does not get form data

Dialog does not get form data

I'm not good with English, sorry.

Working with ZF 1.12, I require my forms use modals to the problem is to use jquery, it does not recover form data saved also one see the alleged information I can not reopen the modal with the button, this is my jquery:

$(function() {
    var name     = $( '#name' ),
        defecto = $( '#defecto' );
   
    $( "#dialog-form" ).dialog({
        autoOpen: false,
        height: 300,
        width: 350,
        modal: true,
        buttons: {
            "Guardar": function() {
                $.post('/permisos/index/add #container',{name: name.val(),defecto: defecto.val()},
                    function(){
                    $('#info').load('/permisos #wtable');
                });
                alert(name.val() + defecto.val()),               
                $( this ).dialog( "close" );
            },
            Cancel: function() {
                $( this ).dialog( "close" );
            }
        },
        close: function() {
            allFields.val( "" ).removeClass( "ui-state-error" );
        }       
    });

    $( "#create-user" )
        .button()
        .click(function() {
            $( "#dialog-form" ).load('/permisos/index/add #container').dialog("open");
        });
});


































and this my html

<form id="permisos" enctype="application/x-www-form-urlencoded" 
class="wufoo" action="" method="post">
<dl class="zend_form"> <input type="hidden" name="id" value="" id="id" /> <dt id="name-label"><label for="name" class="required">Usuario:</label></dt> <dd id="name-element"> <input type="text" name="name" id="name" value="" /></dd> <dt id="defecto-label"><label for="defecto" class="required">Valor:</label></dt> <dd id="defecto-element"> <input type="text" name="defecto" id="defecto" value="" /></dd></dl></form>
please help