Solved

Handle Success from AJAX call

Posted on 2013-05-10
3
356 Views
Last Modified: 2013-05-10
I would like to handle a successful return from the submit below and reload the current page. How can i best achieve this?

           

         $('#modal-confirm').click(function() {
            $(form).ajaxSubmit();
            $(form).resetForm();
            $('#myModalOne').modal('toggle');


        });

Open in new window



Thanks
0
Comment
Question by:WalterRR
  • 2
3 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 500 total points
ID: 39156830
$(document).ajaxSuccess(function() { // http://api.jquery.com/ajaxSuccess/
     location.realod();
})
$('#modal-confirm').click(function() {
            $(form).ajaxSubmit();
            $(form).resetForm();
            $('#myModalOne').modal('toggle');
});

Open in new window

0
 

Author Closing Comment

by:WalterRR
ID: 39156903
Thanks very much...!
0
 
LVL 82

Expert Comment

by:leakim971
ID: 39156913
you're welcome!
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

OverviewThis article demonstrates a simple search form using AJAX. The purpose of the article is to demonstrate how to use the same code to render a page and javascript (JQuery) and AJAX to make subsequent calls to refine the results. The princip…
Boost your ability to deliver ambitious and competitive web apps by choosing the right JavaScript framework to best suit your project’s needs.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now