protected static function makeFilenameWithExtension($filename, $extension)
{
// the filename can be used in HTTP headers, remove new lines to prevent HTTP header injection
$filename = str_replace(array("\n", "\t"), " ", $filename);
return $filename . "." . $extension;
}
public function sendToBrowserInline($filename) { $filename = ReportRenderer::makeFilenameWithExtension($filename, self::PDF_CONTENT_TYPE); $this->TCPDF->Output($filename, 'I'); }