public function RestfulFormatterBase::getContentTypeHeader in RESTful 7
Returns the content type for the selected output format.
Return value
string The contents for the ContentType header in the response.
Overrides RestfulFormatterInterface::getContentTypeHeader
2 methods override RestfulFormatterBase::getContentTypeHeader()
- RestfulFormatterHalJson::getContentTypeHeader in plugins/
formatter/ hal_json/ RestfulFormatterHalJson.class.php - Returns the content type for the selected output format.
- RestfulFormatterJson::getContentTypeHeader in plugins/
formatter/ json/ RestfulFormatterJson.class.php - Returns the content type for the selected output format.
File
- plugins/
formatter/ RestfulFormatterBase.php, line 39 - Contains RestfulFormatterBase.
Class
- RestfulFormatterBase
- @file Contains RestfulFormatterBase.
Code
public function getContentTypeHeader() {
// Default to the most general content type.
return 'application/hal+json; charset=utf-8';
}