2 // Copyright (C) 2006 Rod Roark <rod@sunsetsystems.com>
4 // This program is free software; you can redistribute it and/or
5 // modify it under the terms of the GNU General Public License
6 // as published by the Free Software Foundation; either version 2
7 // of the License, or (at your option) any later version.
9 require_once("../globals.php");
11 $ffname = $GLOBALS['hylafax_basedir'] . '/recvq/' . $_GET['file'];
13 if (!file_exists($ffname)) {
14 die(xl("Cannot access ") . $ffname);
19 passthru("tiff2pdf $ffname");
21 header("Pragma: public");
23 header("Cache-Control: must-revalidate, post-check=0, pre-check=0");
24 header("Content-Type: application/pdf");
25 header("Content-Length: " . ob_get_length());
26 header("Content-Disposition: inline; filename=" . basename($ffname, '.tif') . '.pdf');