您需要
JSON.parse(response);响应。然后,您应该可以像需要的那样访问它。
var parsed_reply = JSON.parse(response);
编辑实际查看代码后:
PHP
<?php$data['example'] = "test";echo json_enpre($data);?>
JAVAscript
<script>$.ajax({ type: 'POST', url: 'example.php', data: {map: map}, cache: false, dataType: 'json',success: function(response) { console.log(response['example']); }});</script>输出:“测试”



