Hola, estoy aprendiendo a usar el FPDF, copio el ejemplo basico:
<?php
require('fpdf.php');
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial','B',16);
$pdf->Cell(40,10,'¡Hola, Mundo!');
$pdf->Output();
?>
y cuando lo ejecuto en lugar de abrir un pdf me abre el siguiente codigo:
%PDF-1.3
3 0 obj
<</Type /Page
/Parent 1 0 R
/Resources 2 0 R
/Contents 4 0 R>>
endobj
4 0 obj
<</Filter /FlateDecode /Length 73>>
stream
xœ3Rðâ2Ð35W(çr
QÐw3T04Ó30PISp
êZ*˜[š€…¤(h,ôÈÏIÔQð-ÍKÉWÔTÉ)*7¯
endstream
endobj
1 0 obj
<</Type /Pages
/Kids [3 0 R ]
/Count 1
/MediaBox [0 0 595.28 841.89]
>>
endobj
5 0 obj
<</Type /Font
/BaseFont /Helvetica-Bold
/Subtype /Type1
/Encoding /WinAnsiEncoding
>>
endobj
2 0 obj
<</ProcSet [/PDF /Text /ImageB /ImageC /ImageI]
/Font ><<
/F1 5 0 R
>>
>>
endobj
6 0 obj
<<
/Producer (FPDF 1.52)
/CreationDate (D:20061012132839)
>>
endobj
7 0 obj
<<
/Type /Catalog
/Pages 1 0 R
/OpenAction [3 0 R /FitH null]
/PageLayout /OneColumn
>>
endobj
xref
0 8
0000000000 65535 f
0000000229 00000 n
0000000417 00000 n
0000000009 00000 n
0000000087 00000 n
0000000316 00000 n
0000000505 00000 n
0000000581 00000 n
trailer
<<
/Size 8
/Root 7 0 R
/Info 6 0 R
>>
startxref
684
%%EOF
QUE ME ESTA PASANDO?? gracias