Laminas Diactoros v1.2.0 Release Notes
Release Date: 2015-11-24 // over 8 years ago-
➕ Added
- ⚡️ zendframework/zend-diactoros#88 updates the
SapiEmitter
to emit aContent-Length
header with the content length as reported by the response body stream, assuming thatStreamInterface::getSize()
returns an integer. - zendframework/zend-diactoros#77 adds a new
response type,
Laminas\Diactoros\Response\TextResponse
, for returning plain text responses. By default, it sets the content type totext/plain; charset=utf-8
; per the other response types, the signature isnew TextResponse($text, $status = 200, array $headers = [])
. - zendframework/zend-diactoros#90 adds a new
Laminas\Diactoros\CallbackStream
, allowing you to back a stream with a PHP callable (such as a generator) to generate the message content. Its constructor accepts the callable:$stream = new CallbackStream($callable);
🗄 Deprecated
- Nothing.
✂ Removed
- Nothing.
🛠 Fixed
- ⚡️ zendframework/zend-diactoros#77 updates the
HtmlResponse
to set the charset to utf-8 by default (if no content type header is provided at instantiation).
- ⚡️ zendframework/zend-diactoros#88 updates the