| @@ 1066-1078 (lines=13) @@ | ||
| 1063 | } |
|
| 1064 | switch ($dest) |
|
| 1065 | {
|
|
| 1066 | case 'I': |
|
| 1067 | // Send to standard output |
|
| 1068 | $this->_checkoutput(); |
|
| 1069 | if (PHP_SAPI != 'cli') |
|
| 1070 | {
|
|
| 1071 | // We send to a browser |
|
| 1072 | header('Content-Type: application/pdf');
|
|
| 1073 | header('Content-Disposition: inline; filename="'.$name.'"');
|
|
| 1074 | header('Cache-Control: private, max-age=0, must-revalidate');
|
|
| 1075 | header('Pragma: public');
|
|
| 1076 | } |
|
| 1077 | echo $this->buffer; |
|
| 1078 | break; |
|
| 1079 | case 'D': |
|
| 1080 | // Download file |
|
| 1081 | $this->_checkoutput(); |
|
| @@ 1079-1088 (lines=10) @@ | ||
| 1076 | } |
|
| 1077 | echo $this->buffer; |
|
| 1078 | break; |
|
| 1079 | case 'D': |
|
| 1080 | // Download file |
|
| 1081 | $this->_checkoutput(); |
|
| 1082 | header('Content-Type: application/pdf');
|
|
| 1083 | // header('Content-Type: application/x-download');
|
|
| 1084 | header('Content-Disposition: attachment; filename="'.$name.'"');
|
|
| 1085 | header('Cache-Control: private, max-age=0, must-revalidate');
|
|
| 1086 | header('Pragma: public');
|
|
| 1087 | echo $this->buffer; |
|
| 1088 | break; |
|
| 1089 | case 'F': |
|
| 1090 | // Save to local file |
|
| 1091 | $f = fopen($name, 'wb'); |
|