Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

FPDF out put Pdf file show I/O error.

Status
Not open for further replies.

amanyasin

Technical User
Feb 7, 2003
28
0
0
Dear all,
i want to create PDF using FPDF.

<?php
require('pdf/fpdf.php');

$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial','B',16);
$pdf->Cell(40,10,'Hello World!');
$pdf->Output();
?>

it runs without any error but when PDF viewer(Acrobate reader) try to open, it shows an I/O error and halt.

please guide me how i can create PDF.
 
make sure that this code is the ONLY thing on the page. no white space at all, no blank lines etc. Neither before nor after
Code:
<?php
require('pdf/fpdf.php');
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial','B',16);
$pdf->Cell(40,10,'Hello World!');
$pdf->Output();
?>
 
yes, i also try with no spaces. when Acrobat Reader try to open it, after saveral minute it displays I/O error,request time out.
 
I am unable to replicate this. I have just downloaded fpdf, installed it on my local webserver (apache) and ran the script you posted. It worked (very fast) and properly.

As always, it is exceptionally difficult to debug user's problems if they cannot be replicated on our test system.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top