JavaScript / Jquery call controller synchroneousely -


i need synchronously call controller (url) in javascript. ajax function so:

$.ajax({   type: 'post',   url: base + '/publication/storeworldcat',   data: data,   success: success,   datatype: datatype,   async:false }); 

i don't understand why should use ajax function async:false parameter ajax asynchronous definition. $post() asynchronous too.

is there better way?

thanks help!

looking @ the documentation of jquery.ajax (quoting) :

by default, requests sent asynchronously (i.e. set true default). if need synchronous requests, set option false.


Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -