Why I can't read json output?

Why I can't read json output?

Hi,

I have this json output in my console:


new_user.js:310 { "UserDetails" :[{"first_name":"ةةة","last_name":"ضضضض","email_address":" jrahma@gmail.com","user_guid":"265aec7f-40cb-11e7-83e2-0cc47a4422ed","activation_guid":"265aec9f-40cb-11e7-83e2-0cc47a4422ed","activation_check_guid":"265aeca3-40cb-11e7-83e2-0cc47a4422ed","user_language":"EN"}]}


I am trying to read it using 

  1. console.log(data.UserDetails[0].first_name);

but getting:

  1. Error: 'Uncaught TypeError: Cannot read property '0' of undefined', line 311, file 'http://localhost:59783/views/new_user.js'.

Kindly help..


Thanks,
Jassim