$v) { $head .= "{$k}: {$v}\r\n"; } } $head .= "\r\n"; $head .= trim($query); fwrite($fp, $head); usleep(20000); fclose($fp); } catch (\Exception $exc) { Log::debug('SyncHttpService error==='); Log::debug(compact('host', 'port', 'errno', 'errstr')); Log::debug(compact('params', 'query')); Log::debug('SyncHttpService error==='); writeLog($goUrl, 'SyncHttpServiceError'); writeLog(compact('host', 'port', 'errno', 'errstr'), 'SyncHttpServiceError'); writeLog(compact('params', 'query'), 'SyncHttpServiceError'); writeLog($exc, 'SyncHttpServiceError'); } } }