Php 如何在一段时间内跳过一行
我正在尝试使用函数FPDF将php转换为pdf,但我在数据库中进行了选择,我希望将此选择的所有元素都转换为pdf:Php 如何在一段时间内跳过一行,php,mysql,fpdf,Php,Mysql,Fpdf,我正在尝试使用函数FPDF将php转换为pdf,但我在数据库中进行了选择,我希望将此选择的所有元素都转换为pdf: $query="select organisme,id from client"; $resultats=$db->query($query); $pdf=new FPDF(); $pdf->AliasNbPages(); $pdf->AddPage(); $pdf->SetFillColor(232,232,232); $pdf->SetFont('
$query="select organisme,id from client";
$resultats=$db->query($query);
$pdf=new FPDF();
$pdf->AliasNbPages();
$pdf->AddPage();
$pdf->SetFillColor(232,232,232);
$pdf->SetFont('Arial','B',12);
$pdf->Cell(20,6,'ID',1,0,'C',100);
$pdf->Cell(70,6,'mes organismes',1,0,'C',1);
$pdf->SetFont('Arial','',10);
while ($row = $resultats->fetch(PDO::FETCH_ASSOC))
{
$pdf->Cell(20,6,utf8_decode($row['id']),1,0,'C',1);
$pdf->Cell(70,6,$row['organisme'],1,0,'C',1);
}
$pdf->Output();
?>
但问题是我拿到了身份证,但我有个问题:
我想知道我该怎么做才能跳进所有新的身份证和组织我
谢谢FPDF的Ln()
函数执行换行操作
$pdf->Ln();
将这一行添加到$pdf->Cell()
函数调用下方,包括标题行和while
循环内部