Advertisement
Guest User

Untitled

a guest
May 17th, 2018
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.57 KB | None | 0 0
  1. $(document).ready(function () {
  2.  
  3. var email = document.getElementById("email-field");
  4. var password = document.getElementById("password-field");
  5.  
  6. function login() {
  7. console.log("User logging in");
  8.  
  9. var user = {
  10. email: email.val(),
  11. password: password.val()
  12. }
  13.  
  14. $.ajax({
  15. type: 'POST',
  16. url: '/Home/Login',
  17. dataType: 'json',
  18. data: user,
  19. success: function(result) {
  20.  
  21. console.log(result)
  22.  
  23. }
  24. });
  25.  
  26. }
  27.  
  28.  
  29. })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement