Is there a formula for successfully processing a form within a window, 
where the form is retrieved by an AjaxRequest? In my own convoluted way, 
I have it working to the point that the form is displayed, then handled 
and submitted properly, but I'm not able to capture (or block) the 
return from the form submission. This is within the context of the 
symfony environment.

 <script type="text/javascript">
   var win;

function test()
{
       var currentTime = new Date();
       var id = "window_id_" + currentTime.getTime();
       win = new Window(id, {className: "dialog", width:450, height:680, 
zIndex: 100, title: "create customer"});
       win.setAjaxContent("/index.php/customer/createJSW", {method: 
'get'}, true, true);
}

myObserver = {
           onDestroy:
               function(eventName, win1) {
                   if (win1 == win) {
                       win = null;
                       self.location.reload();
                       Windows.removeObserver(this);
                       }
                   }
               }
       Windows.addObserver(myObserver);
   </script>


   <a class="ancillary" href="#" onclick="test();return false;">[add 
customer]</a>

I'd also like to be able to reload the primary window once the js window 
is closed/destroyed - I assume the best way to handle this is via an 
observer?

_______________________________________________
Javawin mailing list
[email protected]
http://mail.xilinus.com/mailman/listinfo/javawin_xilinus.com

Reply via email to