Advertisement
benshepherd

Untitled

Dec 10th, 2013
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. function completeApplication()
  2. {
  3. $.post("complete-application.php", {code: $("[name=code]").val()}, function(d) {
  4. var obj = null;
  5. try
  6. {
  7. obj = JSON.parse(d);
  8.  
  9. if(obj.status == true)
  10. {
  11. window.location = 'complete-application.php';
  12. }
  13. else
  14. {
  15. alert(obj.message);
  16. }
  17. }
  18. catch (err)
  19. {
  20. alert("There was a problem reading server response: " + err);
  21. }
  22. });
  23.  
  24. return false;
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement