protected function outputContentType($format)
    {
        if (!isset($format)) {
            $contentType = $this->getResponse()->getHeaderLine('Content-Type');
            
            if (empty($contentType)) {
                $format = $this->defaultFormat ?: 'text/html';
            }
        }
        
        if (empty($contentType)) {
            $contentType = $this->getContentType($format);
            $this->setResponseHeader('Content-Type', $contentType);
        }
        
        return $contentType;
    }
protected function outputContentType($format)
    {
        if (!isset($format)) {
            $contentType = $this->getResponse()->getHeaderLine('Content-Type');
            
            if (empty($contentType)) {
                $format = $this->defaultFormat ?: 'text/html';
            }
        }
        
        if (empty($contentType)) {
            $contentType = $this->getContentType($format);
            $this->setResponseHeader('Content-Type', $contentType);
        }
        
        return $contentType;
    }
protected function outputContentType ( $ format ) { if ( ! isset ( $ format ) ) { $ contentType = $ this -> getResponse ( ) -> getHeaderLine ( 'Content-Type' ) ; if ( empty ( $ contentType ) ) { $ format = $ this -> defaultFormat ? : 'text/html' ; } } if ( empty ( $ contentType ) ) { $ contentType = $ this -> getContentType ( $ format ) ; $ this -> setResponseHeader ( 'Content-Type' , $ contentType ) ; } return $ contentType ; }
Set the content type for the output

@param string $format
@return string
Set the content type for the output