function Response::__toString
Same name in this branch
- 11.1.x vendor/symfony/browser-kit/Response.php \Symfony\Component\BrowserKit\Response::__toString()
Returns the Response as an HTTP string.
The string representation of the Response is the same as the one that will be sent to the client only if the prepare() method has been called before.
See also
prepare()
File
-
vendor/
symfony/ http-foundation/ Response.php, line 217
Class
- Response
- Response represents an HTTP response.
Namespace
Symfony\Component\HttpFoundationCode
public function __toString() : string {
return \sprintf('HTTP/%s %s %s', $this->version, $this->statusCode, $this->statusText) . "\r\n" . $this->headers . "\r\n" . $this->getContent();
}