javascript - Ajax result is not an object -


My AJAX result is

  ["1", "O"]   

I'm trying to reach 1, but

  console.log (Results [0]);   

gives me

'['

How can I make it as an object and Can I already get the element of my array result?

Try it that you are listed in the string of your result

  var resultObj = JSON.parse (results); Console.log (resultsObj [0]);    

Comments

Popular posts from this blog

Android - Facebook GraphUser has no email attribute -

Opencart and VQMOD issue: Could not load controller in vq2-system_engine_controller.php -

deployment - How to upload Parent child SSIS package to server -