This is my code to create a report from details of guest table. but it gives following error.
Parse error: syntax error, unexpected ')' in /home/a5899527/public_html/cpanel/testrep2.php on line 17
<?php
include("connect.php");
$SQL="SELECT * FROM guest ";
$run=mysql_query($SQL,$con) or die ("SQL error");
$row=mysql_fetch_array($run);
require('/fpdf.php');
$pdf = new FPDF();
$pdf->AddPage();
$pdf->SetFont('Arial','B',12);
foreach($header as $heading) {
foreach($heading as $column_heading)
$pdf->Cell(90,12,$column_heading,1);
}
foreach($row) {
$pdf->SetFont('Arial','',12);
$pdf->Ln();
foreach($row as $column)
$pdf->Cell(90,12,$column,1);
}
$pdf->Output();
?>
please give a solution? Line 17 is foreach($row) {