Ich habe schon einige Tage hier im Forum gelesen und habe auch gesehen, dass es wohl 100 mal schon vorgekommen ist. Allerdings finde ich keinen Lösungsansatz.
Ich teste das script lokal mit XAMPP und auch online. Dies ist die DAtei:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Hier Titel eintragen</title>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
</head>
<body>
<?php
require('fpdf.php');
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial','B',16);
$pdf->Cell(40,10,'Hello World!');
$pdf->Output();
?>
</body>
</html>
Fehler:
\htdocs\html\test\fpdf.php on line 1022
FPDF error: Some data has already been output to browser, can't send PDF file
Ich teste das script lokal mit XAMPP und auch online. Dies ist die DAtei:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title>Hier Titel eintragen</title>
<meta http-equiv="content-type" content="text/html; charset=iso-8859-1">
</head>
<body>
<?php
require('fpdf.php');
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial','B',16);
$pdf->Cell(40,10,'Hello World!');
$pdf->Output();
?>
</body>
</html>
Fehler:
\htdocs\html\test\fpdf.php on line 1022
FPDF error: Some data has already been output to browser, can't send PDF file

... ich habe das mal gemacht und es klappt. nun habe ich mir von der fehlermeldung mal den Quellcode angesehen und da stand das ganze mit dem HTML Header noch drinnen .. kann es sein, dass das ganze html einfach mit übertragen wird und dass dann den fehler verursacht???
Kommentar