Advertisement
Guest User

Untitled

a guest
Jul 20th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. // your custom app logic goes here:
  2.  
  3. (function(){
  4. var turbo = Turbo({
  5. site_id: 'APP_ID'
  6. })
  7.  
  8. $('#btn-register').click(function(event){
  9. event.preventDefault()
  10.  
  11. // These values should come from a form tag in an html document:
  12. var userInfo = {
  13. firstName: 'michael',
  14. lastName: 'jordan',
  15. username: 'mj23',
  16. password: 'chicagobulls'
  17. }
  18.  
  19. turbo.createUser(userInfo, function(err, data){
  20. if (err){
  21. alert('Error:' + err.message)
  22. return
  23. }
  24.  
  25. alert('User Created: ' + JSON.stringify(data))
  26. })
  27. })
  28.  
  29. })()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement