Guest User

Untitled

a guest
Jun 21st, 2018
101
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. <script type="text/javascript">
  2.  
  3. $(function () {
  4. var $pleaseWaitDialog= $("#pleaseWaitDialog");
  5.  
  6. $(document).on("submit", "#back", function (e) {
  7.  
  8. $pleaseWaitDialog.dialog({ modal: true });
  9.  
  10. $.fileDownload($(this).prop('action'), {
  11. httpMethod: 'POST',
  12. data: $(this).serialize,
  13. successCallback: function (url) {
  14. $pleaseWaitDialog.dialog('close');
  15. },
  16. failCallback: function (responseHtml, url) {
  17. $pleaseWaitDialog.dialog('close');
  18. }
  19. });
  20. e.preventDefault; //otherwise normal form submit will occur
  21. });
  22. });
  23. </script>
Add Comment
Please, Sign In to add comment