Ver Mensaje Individual
  #3 (permalink)  
Antiguo 31/05/2013, 09:45
wilmer30
 
Fecha de Ingreso: enero-2010
Mensajes: 491
Antigüedad: 14 años, 3 meses
Puntos: 12
Respuesta: Integrar form en modal jquery UI

Encontre una funcrion .load() de jquery el cual si debería abrir el fomulario, no conosco bien jquery, pero realizando algunos ejemplo si funciona, pero en este caso:

Código Javascript:
Ver original
  1. $( "#dialog-form" ).dialog({
  2.         autoOpen: false,
  3.         height: 400,
  4.         width: 450,
  5.         modal: true,
  6.         buttons: {
  7.             "Create an account": function() {
  8.             },
  9.             Cancel: function() {
  10.                 $( this ).dialog( "close" );
  11.             }
  12.         }
  13.     });
  14.  
  15.     $( "#create-user" )
  16.         .button()
  17.         .click(function() {
  18.             $( "#dialog-form" ).load('/index/add').dialog("open");
  19.         });

y en mi vista tengo
Código HTML:
Ver original
  1. <div id="dialog-form" title="Create new user"></div>
  2.     <button id="create-user" style='background:url("images/new_act.jpg") center no-repeat;' title='Nuevo'>&nbsp;</button>
Se abre el modal pero con un mensaje de error:
Cita:
Fatal error: Uncaught exception 'Zend_Controller_Action_Exception' with message 'Action "add" does not exist and was not trapped in __call()' in C:\xampp\php\library\Zend\Controller\Action.php:48 5