/** * Get the PDF temporary folder and create it if necessary * * @return string The absolute PDF temporary folder's path * @access private * @static * @since 1.0.0 */ private static function getPdfTmpFolder() { if (ApiPrint::$pdf_tmp_folder === null) { $folder = PRINT_TMP . '/pdf'; if (file_exists($folder) === false || is_dir($folder) === false) { if (mkdir($folder, 0777, true) === false) { throw new Exception('Impossible to create HTML temp folder'); } } ApiPrint::$pdf_tmp_folder = $folder; } return ApiPrint::$pdf_tmp_folder; }