|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2001-01-10 07:30 UTC] sniper@php.net
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sat Oct 25 03:00:01 2025 UTC |
Memory fault when having a image in the PDF Document Only with php-4.0.4 with php-4.0.3pl1 it was OK. The same behaviour when used with a .png image. Also the same behaviour when using pdflib-3.0 or pdflib-3.0.3. Testscript: <? $tempfile = tempnam ("/tmp", "pdf"); $fp = fopen("$tempfile", "w"); $pdf = pdf_open($fp); pdf_set_info($pdf, "Author", "Peter Caflisch"); pdf_set_info($pdf, "Title", "Test"); pdf_set_info($pdf, "Creator", "Peter Caflisch"); pdf_set_info($pdf, "Subject", "erstellt am: $datum"); pdf_begin_page($pdf, 595, 842); pdf_add_outline($pdf, "Seite ".$seite. " A.." ); $im = pdf_open_image_file($pdf, "gif", "efdlogo.gif"); pdf_place_image($pdf, $im, 18, 790, 0.8); pdf_close_image($pdf, $im); pdf_end_page($pdf); pdf_end_page($pdf); pdf_close($pdf); fclose($fp); $fp1 = fopen("$tempfile", "r"); header("Content-type: application/pdf"); fpassthru($fp1); unlink ($tempfile); ?> RESULTS ----------- with php-4.0.4: >php testpdf.php >Memory fault with php-4.0.3pl1: >php testpdf.php > Is the same as a apache module. CONFIG: tar -xvf ../number4.tar CC=gcc ./configure --with-mysql=/appl/mysql --enable-bcmath --with-imap=/appl/imap \ --without-iodbc --without-udbc --with-openlink=/appl --with-pdflib --without-yaz \ --with-gd --with-zlib-dir=/appl/zlib --with-ldap --with-jpeg-dir=/appl/jpeg-6b \ --enable-ftp --enable-track-vars make make install