note 27837 deleted from ref.pdf by didou

From: Date: Sat, 09 Aug 2003 13:45:08 +0000
Subject: note 27837 deleted from ref.pdf by didou
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-53739@lists.php.net to get a copy of this message
Note Submitter: ---- If you got this message you have already installed de pdflib. I had the same problem you have and did following changes, and it works <?php $pdf = pdf_new(); PDF_open_file($pdf, ""); PDF_set_info($pdf, "Creator", "hello.php"); PDF_set_info($pdf, "Author", "Rainer Schaaf"); PDF_set_info($pdf, "Title", "Hello world (PHP)"); pdf_begin_page($pdf, 595, 842); pdf_add_outline($pdf, "Page 1"); pdf_set_font($pdf, "Times-Roman", 30, "host"); pdf_set_value($pdf, "textrendering", 1); pdf_show_xy($pdf, "Times Roman outlined", 50, 750); pdf_moveto($pdf, 50, 740); pdf_lineto($pdf, 330, 740); pdf_stroke($pdf); pdf_end_page($pdf); pdf_close($pdf); $buf = PDF_get_buffer($pdf); $len = strlen($buf); header("Content-type: application/pdf"); header("Content-Length: $len"); header("Content-Disposition: inline; filename=hello.pdf"); print $buf; pdf_delete($pdf); echo "<A HREF=getpdf.php>finished</A>"; ?>

« previous php.notes (#53739) next »