-4

On AJAX request response is following :

[  {"status":{"login":"invalid"}},
   {"user":{"username":false,"pwd":false}}
]

How to read values in Jquery.

1 Answers1

0

Use JSON.parse(string) to get an Object. After that you can access values as default:

var json = JSON.parse(res.data)
console.log(json.status.login)
Felix Gaebler
  • 702
  • 4
  • 23