';
}
if($set_ord['cust_address']!='' || $set_ord['gst_no']!=NULL){
$contentWithNewlines = str_replace("
", "\n", $set_ord['cust_address']);
}
$bill_id=' '.sprintf("%04d", $set_ord['bill_id']);
$created = date('d-m-Y', strtotime($set_ord['created_at']));
if($set_deal['gst']!='GST'){
$gst_no1=' GST NO:'.$set_deal['gst'].'
';
}
$pdf = new TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false);
// set document information
$pdf->SetCreator(PDF_CREATOR);
$pdf->SetAuthor('Nicola Asuni');
$pdf->SetTitle('Payment Receipt');
$pdf->SetSubject('TCPDF Tutorial');
$pdf->SetKeywords('TCPDF, PDF, example, test, guide');
// remove default header/footer
$pdf->setPrintHeader(false);
$pdf->setPrintFooter(false);
// set default monospaced font
$pdf->SetDefaultMonospacedFont(PDF_FONT_MONOSPACED);
// set margins
$pdf->SetMargins(PDF_MARGIN_LEFT, PDF_MARGIN_TOP, PDF_MARGIN_RIGHT);
// set auto page breaks
$pdf->SetAutoPageBreak(TRUE, PDF_MARGIN_BOTTOM);
// set image scale factor
$pdf->setImageScale(PDF_IMAGE_SCALE_RATIO);
// set some language-dependent strings (optional)
if (@file_exists(dirname(__FILE__).'/lang/eng.php')) {
require_once(dirname(__FILE__).'/lang/eng.php');
$pdf->setLanguageArray($l);
}
// ---------------------------------------------------------
// set font
// add a page
$pdf->SetFont('times', 'A4', 12);
$pdf->AddPage();
// set some text to print
$html= <<
$set_deal[name] $add_text $set_deal[city] $set_deal[state] $set_deal[postcode] MOBILE: $set_deal[phone] |
$set_ord[cust_name] $contentWithNewlines $set_sate[state] $set_ord[cust_pin] $gst_no MOBILE: $set_ord[cust_phone] |
INVOICE NO.:$bill_id INVOICE DATE :$created $gst_no1 |