I want to create below the image format in fpdf. i try to write code in fpdf for that image which is shown below but when pdf comes design is not same as image below .So But How can i design the below the image format in fpdf.
<?php
include("database/db.php");
$branch_name=$_POST['branch_name'];
$name=$_POST['name'];
$course=$_POST['course'];
$month=$_POST['from']. " - " .$_POST['to'];
$payment_date=$_POST['payment_date'];
extract($_POST);
$sql="Update studentfees set `paid`='{$paid}',`due`='{$due}',`month`='$month',`payment_date`='$payment_date' where roll='{$_REQUEST['roll']}'";
$result=mysql_query($sql);
date_default_timezone_set("Asia/Kolkata");
$date=date("d-m-Y");
require("fpdf/fpdf.php");
$pdf=new FPDF();
$pdf->AddPage();
$pdf->SetFont("Arial","",14);
$pdf->Cell(170,10,"Sigma Training Institute ",0,1,'C');
$pdf->Cell(70,10,"",0,1);
$pdf->Cell(100,10,"Candidate Copy",1,0,"C");
$pdf->Cell(70,10,"",0,1);
$pdf->Cell(70,10,"",0,1);
$pdf->Cell(20,10,"Date",1,0);
$pdf->Cell(40,10,"$date",1,0,"C");
$pdf->Cell(20,10,"",0,0);
$pdf->Cell(30,10,"Receipt No",1,0,'R');
$pdf->Cell(30,10,"$date",1,1,"R");
$sql1="Select * from studentfees where roll='{$_REQUEST['roll']}'";
$result1=mysql_query($sql1);
if($dtset=mysql_fetch_array($result1))
{
$pdf->Cell(70,10,"Candidate Name :-",0,0);
$pdf->MultiCell(110,10,$dtset['name'],0,1);
$pdf->Cell(70,10,"Candidate Course :-",0,0);
$pdf->MultiCell(110,10,$dtset['course'],0,1);
$pdf->Cell(70,10,"Total Course Fees ",0,0);
$pdf->MultiCell(70,10,$dtset['total_fee'],0,1);
$pdf->Cell(70,10,"Amout Paid:- ",0,0);
$pdf->MultiCell(70,10,$dtset['paid'],0,1);
$pdf->Cell(70,10,"Candidate Roll Number:- ",0,0);
$pdf->MultiCell(70,10,$dtset['roll'],0,1);
$pdf->Cell(70,10,"Due Amout:- ",0,0);
$pdf->MultiCell(70,10,$dtset['due'],0,1);
$pdf->Cell(70,10,"Payment Date:- ",0,0);
$pdf->MultiCell(70,10,$dtset['payment_date'],0,1);
$pdf->Cell(70,10,"",0,1);
$pdf->Cell(70,10,"_________________________________________________________________",0,1);
$pdf->Cell(70,10,"",0,1);
$pdf->output();
}
?>