public function send()
    {
        header(
            sprintf(
                'HTTP/1.1 %s %s',
                $this->statusCode,
                self::codeToReason($this->statusCode)
            )
        );
        foreach ($this->headers as $k => $v) {
            header(
                sprintf('%s: %s', $k, $v)
            );
        }
        echo $this->body;
    }
public function send()
    {
        header(
            sprintf(
                'HTTP/1.1 %s %s',
                $this->statusCode,
                self::codeToReason($this->statusCode)
            )
        );
        foreach ($this->headers as $k => $v) {
            header(
                sprintf('%s: %s', $k, $v)
            );
        }
        echo $this->body;
    }
public function send ( ) { header ( sprintf ( 'HTTP/1.1 %s %s' , $ this -> statusCode , self :: codeToReason ( $ this -> statusCode ) ) ) ; foreach ( $ this -> headers as $ k => $ v ) { header ( sprintf ( '%s: %s' , $ k , $ v ) ) ; } echo $ this -> body ; }
Construct the response and send it out.
Construct the response and send it out .