how to get data to javascript from php using json_encode?

后端 未结 7 2042
梦如初夏
梦如初夏 2020-12-29 12:20

I am trying to map traceroutes to google maps.

I have an array in php with traceroute data as

$c=ip,latitude,longitude, 2nd ip, its latitude, longitu         


        
相关标签:
7条回答
  • 2020-12-29 12:53

    we have to display the json encode format in javascript , by using below one:

    var responseNew = JSON.parse(' {"name" : "John"} ' );
    alert(responseNew['name']);
    
    0 讨论(0)
提交回复
热议问题