解决json跨域时错误:SyntaxError: invalid label 将数据做以下返回: $callback = $_GET['callback']; echo $callback.'('.json_encode(array('html'=>$html)).')';