SHARE
TWEET

Untitled

a guest Dec 13th, 2016 70 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function registerUser(e) {
  2. e.preventDefault();
  3.  
  4. let userData = {
  5.     username: $("#registerUsername").val(),
  6.     password: $("#registerPassword").val()
  7. };
  8. $.ajax({
  9.     method: "POST",
  10.     url: kinveyBaseUrl + '/user/' + kinveyAppKey,
  11.     headers: kinveyAppAuthHeaders,
  12.     data: userData,
  13.     success: registerSuccess,
  14.     error: handleAjaxError
  15. });
  16. function registerSuccess(userInfo) {
  17.     saveAuthInSession(userInfo);
  18.     showInfo("User Successfully Registered");
  19. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top