1
This commit is contained in:
+7
-2
@@ -87,8 +87,13 @@ class AsyncClient extends ClientAbstracts
|
|||||||
$this->withAddedHeader('User-Agent', $this->getAgent());
|
$this->withAddedHeader('User-Agent', $this->getAgent());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$path = $this->setParams($path, $data);
|
$path = $this->setParams($path, $data);
|
||||||
|
|
||||||
|
$content = $this->getData()->getContents();
|
||||||
|
|
||||||
|
$this->withAddedHeader('Content-Length', $this->getData()->getSize());
|
||||||
|
|
||||||
$array = [];
|
$array = [];
|
||||||
$array[] = strtoupper($this->getMethod()) . ' ' . $path . ' HTTP/1.1';
|
$array[] = strtoupper($this->getMethod()) . ' ' . $path . ' HTTP/1.1';
|
||||||
if (!empty($this->getHeader())) {
|
if (!empty($this->getHeader())) {
|
||||||
@@ -97,9 +102,9 @@ class AsyncClient extends ClientAbstracts
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
$array = implode("\r\n", $array) . "\r\n\r\n";
|
$array = implode("\r\n", $array) . "\r\n\r\n";
|
||||||
$this->client->send($array . $this->getData()->getContents());
|
$this->client->send($array . $content);
|
||||||
|
|
||||||
var_dump($array . $this->getData()->getContents());
|
var_dump($array . $content);
|
||||||
|
|
||||||
$revice = $this->client->recv();
|
$revice = $this->client->recv();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user