Advertisement
Nikitosich12

Untitled

Apr 26th, 2018
63
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. $result = array(
  2. 'name' => "no"
  3. );
  4. echo json_encode($result);
  5.  
  6. Вот код js
  7.  
  8. $('#authbtn').bind('click', function() {
  9. $.post('/core/auth.php',
  10. {
  11. 'authlogin':$('#authlogin').val(),
  12. 'pass':$('#pass').val()
  13. },
  14. function(response){
  15. result = $.parseJSON(response);
  16. if (result.name=='no'){
  17. noty({ text: 'Успешная регистрация!!!'});
  18. }
  19. });
  20. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement