PHP用CURL发送Content-type为application/json的POST和GET请求方法
functionjson_post($url,$data=NULL){$curl=curl_init();curl_setopt($curl,CURLOPT_URL,$url);curl_setopt($curl,CURLOPT_SSL_VERIFYPEER,false);curl_setopt($curl,CURLOPT_SSL_VERIFYHOST,false);if(!$data){retu