function fspost($path,$data){ $host = request()->host(); $post = http_build_query($data); $len = strlen($post); $fp = fsockopen( $host , 80, $errno, $errstr, 3); if ($fp) { $header = "POST $path HTTP/1.1 "; $header .= "Host: $host "; $header .= "Content-type: application/x-www-form-urlencoded "; $header .= "Connection: Close "; $header .= "Content-Length: $len "; $header .= " "; $header .= $post." "; fwrite($fp, $header); fclose($fp); } }