eddy556 Posted November 29, 2006 Share Posted November 29, 2006 I'm having trouble with this code, I am trying to use sessions with FPDF, I have already had this script working but changed it somehow lol and cant get it back, I keep getting header already sent problems.THanks<?phprequire ("fpdf.php");$date = date('l dS \of F Y');$pdf=new FPDF();session_start();$userID = $_SESSION['userid'];$pdf->AddPage();$pdf->SetFont('Arial','B',16);$pdf->Cell(40,10,"Planes R' Us Invoice");$pdf->Ln(6);$pdf->SetFont('Courier','B',8);$pdf->SetXY(120, 30);$pdf->Cell(40,5, 'Invoice created on:');$pdf->SetFont('Courier','',8);$pdf->SetXY(120, 30);$pdf->Cell(40,10, $date);$pdf->SetFont('Courier','B',8);$pdf->SetXY(120, 30);$pdf->Cell(40,20, 'By user:');$pdf->SetFont('Courier','',8);$pdf->SetXY(120, 30);$pdf->Cell(40,25, $userID);$pdf->Output();?> Quote Link to comment https://forums.phpfreaks.com/topic/28860-php-and-fpdf/ Share on other sites More sharing options...
Gmunky Posted May 14, 2007 Share Posted May 14, 2007 have you tried adding this line 'session_cache_limiter('private');' before session_start()? Quote Link to comment https://forums.phpfreaks.com/topic/28860-php-and-fpdf/#findComment-252792 Share on other sites More sharing options...
SamLiu Posted May 21, 2007 Share Posted May 21, 2007 post your fpdf.phpI'm betting something there is overlapping with your code here. Quote Link to comment https://forums.phpfreaks.com/topic/28860-php-and-fpdf/#findComment-258011 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.