To the original poster, i don't have time right now to really delve deep into your code, but just a quick glance raises the question "What is ReloadPage() supposed to do?"... i would have the feeling judging by your code that you expect:
- Ajax call be made - *then* reload the page that is in no way guarenteed to happen since the Ajax call is done asynchronously.... meaning when the code runs, it doesn't "wait" for the call to finish before the call is complete and successful As for: "About the $.ajax, I never use it. Using $.get and $.post is more easy than using $.ajax. I never got any problems with $.get and $.post " Just in case you aren't aware, both "$.get" and "$.post" both call "$.ajax" :-) Right from the jQuery file -------------------------------------- get: function( url, data, callback, type ) { // shift arguments if data argument was ommited if ( jQuery.isFunction( data ) ) { callback = data; data = null; } return jQuery.ajax({ type: "GET", url: url, data: data, success: callback, dataType: type }); }, post: function( url, data, callback, type ) { if ( jQuery.isFunction( data ) ) { callback = data; data = {}; } return jQuery.ajax({ type: "POST", url: url, data: data, success: callback, dataType: type }); }, On Jun 3, 10:38 pm, Donny Kurnia <donnykur...@gmail.com> wrote: > Shadraq wrote: > > Donny > > > Thanks for the tip about Pastie. I so was not aware of that. > > >http://pastie.org/499915 > > I have examine your code. Same with my suggestion before, try to define > $.ajaxStart outside the function, because it just need to defined once > in a page. > > About the $.ajax, I never use it. Using $.get and $.post is more easy > than using $.ajax. I never got any problems with $.get and $.post > > I think you must call ReloadPage() and change the l_processing and > control value inside the callback for ajax call. > > This is the example for login: > $.post("login.php", > dataString, > function(r){ > ReloadPage(); > l_processing = "no"; > control = "no"; > }); > > I Hope it work. > > -- > Donny > Kurniahttp://blog.abifathir.comhttp://hantulab.blogspot.comhttp://www.plurk.com/user/donnykurnia