How to show waiting message during sync ajax call in browser

前端 未结 2 1131
傲寒
傲寒 2020-12-09 06:49

How to show waiting message on sync ajax call in browser ? I tried code below, turned web server off but \"Saving\" message is not displayed.

After some time only er

2条回答
  •  轮回少年
    2020-12-09 07:38

    Loading...

    Your ajax call:

    $('.loading').fadeIn(50, function() {
       $.ajax( 'save',
       {
          async: false,
          type: 'POST'
       } );
    });
    
    $('.loading').fadeOut(50);
    

提交回复
热议问题