//Create a DIV in the popup window and populate it with the AJAX wait
message and graphic.
newDiv = popup.document.createElement(‘div’);
newDiv.setAttribute(‘id’, ‘pdf’);
newDiv.setAttribute(‘style’, ‘margin-top: 250px; text-align:
center;’);
newDiv.innerHTML = ‘Please wait while your forms are
generated
’;
popup.document.body.appendChild(newDiv);
//Submit the form asynchronously and execute Javascript returned from
the action.
new Ajax.Request(form.action, { asynchronous: true, method:
‘post’, parameters: Form.serialize(form), evalScripts:
true,
onSuccess: function(request)
{eval(request.responseText);}
});
return false;
}
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.