<?php

include("../fpdf/fpdf.php");

class PDFReport extends FPDF {

	function __construct ($orientation = 'P', $unit = 'pt', $format = 'Letter', $margin = 40) {

		$this->FPDF($orientation, $unit, $format);

		$this->SetTopMargin($margin);

		$this->SetLeftMargin($margin);

		$this->SetRightMargin($margin);

		

		$this->SetAutoPageBreak(true, $margin);

	}

	

	function Header () {

		$this->SetFont('Arial', 'B', 12);

		$this->SetFillColor(206, 207, 208);

		$this->SetTextColor(0, 0, 0);

		$this->Cell(0, 22, "Client Report - " . $_POST['client_name'], 1, 1, 'C', true);

		$this->Cell(200, 15, " ", 0, 2);

	}

	

	function Footer () {

		$this->SetFont('Arial', '', 10);

		$this->SetTextColor(0);

		$this->SetXY(40, -60);

		$this->Cell(200, 30, " ", 0, 2);

		$this->Cell(0, 20, "Emeras CRM - Client Financial Report", 'T', 0, 'C');

	}
}


$pdf = new PDFReport();

?>