这 可能 是你没有在test.php的回调。此外,
json_enpre仅接受数组:
$results = array("key" => "value");echo $_GET['callback'] . '(' . json_enpre($results) . ')';// the callback stuff is only needed if you're requesting from different domains使用时,jQuery自动切换到JSONP(即使用脚本标签代替
XMLHttpRequest)
http://。如果您在同一域上有test.html和test.php,请尝试使用相对路径(而不使用回调)。



