public function DocumentTypeBase::header in Forena Reports 7.5
5 methods override DocumentTypeBase::header()
- DocRaptorPDF::header in src/
DocumentFormats/ DocRaptorPDF.php - MPDFDocument::header in src/
DocumentFormats/ MPDFDocument.php - PrincePDF::header in src/
DocumentFormats/ PrincePDF.php - SVGDocument::header in src/
DocumentFormats/ SVGDocument.php - XMLDocument::header in src/
DocumentFormats/ XMLDocument.php
File
- src/
DocumentFormats/ DocumentTypeBase.php, line 16 - FrxDocument.inc Given a report, render the appropriate output given the document format. @author davidmetzler
Class
Namespace
Drupal\forena\DocumentFormatsCode
public function header($r, $print = TRUE) {
$r->html = '';
if ($this->content_type) {
header('Content-Type: ' . $this->content_type . ' ;charset=' . $this->charset);
header('Cache-Control:');
header('Pragma:');
$file_name = basename($_GET['q']);
header('Content-Disposition: attachment; filename="' . $file_name . '"');
header('Cache-Control: must-revalidate');
}
$this->print = $print;
}