pdf causes three requests?

From: Date: Wed, 10 May 2000 17:38:25 +0000
Subject: pdf causes three requests?
Groups: php.version4 
Request: Send a blank email to php-version4+get-14771@lists.php.net to get a copy of this message
Using PHP4RC1 and PDF3, the following code causes two problems. First, it does not display the pdf file, but the pdf file is there and if I use it's direct URL, it displays. Seems to only fail on smaller output files. Second, the access log show three accesses to the script, and it does go through the script three times. Why? <?php $fp = fopen("test.pdf", "w"); $pdf = PDF_open($fp); PDF_set_parameter($pdf,"resourcefile","/usr/local/apache/htdocs/pdflib.upr") ; PDF_begin_page($pdf, 595, 842); pdf_set_font($pdf, "Times-Roman", 24, "winansi"); pdf_set_text_rendering($pdf, 0); PDF_set_text_pos($pdf, 50, 750); PDF_show($pdf, "Hello World"); PDF_end_page($pdf); PDF_close($pdf); fclose($fp); $fp2 = fopen("test.pdf", "r"); header("Content-type: application/pdf"); fpassthru($fp2); fclose($fp2); ?> --- www.KeithFord.com ICQ-15705088 Visit www.PalmFoolery.com today! day-800.500.8381 cell-256.603.3932 fax-419.858.8833 info-256.971.9711

« previous php.version4 (#14771) next »