public function getContentType()
    {
        if (isset($this->responseInfo['content_type'])) {
            $contentType = $this->responseInfo['content_type'];
        } else {
            $contentType = isset($this->responseHeaders['Content-Type']) ? $this->responseHeaders['Content-Type'] : null;
        }
        
        if ($contentType) {
            $contentTypeParts = preg_split('/\s*[;,]\s*/', $contentType);
            return strtolower($contentTypeParts[0]);
        }
        
        return null;
    }
public function getContentType()
    {
        if (isset($this->responseInfo['content_type'])) {
            $contentType = $this->responseInfo['content_type'];
        } else {
            $contentType = isset($this->responseHeaders['Content-Type']) ? $this->responseHeaders['Content-Type'] : null;
        }
        
        if ($contentType) {
            $contentTypeParts = preg_split('/\s*[;,]\s*/', $contentType);
            return strtolower($contentTypeParts[0]);
        }
        
        return null;
    }
public function getContentType ( ) { if ( isset ( $ this -> responseInfo [ 'content_type' ] ) ) { $ contentType = $ this -> responseInfo [ 'content_type' ] ; } else { $ contentType = isset ( $ this -> responseHeaders [ 'Content-Type' ] ) ? $ this -> responseHeaders [ 'Content-Type' ] : null ; } if ( $ contentType ) { $ contentTypeParts = preg_split ( '/\s*[;,]\s*/' , $ contentType ) ; return strtolower ( $ contentTypeParts [ 0 ] ) ; } return null ; }
get content type
@return string
get content type