mein-sterntours/app/Libraries/CouponPDF.php
2020-04-15 12:11:42 +02:00

49 lines
No EOL
977 B
PHP

<?php
namespace App\Libraries;
use \setasign\Fpdi\Fpdi;
class CouponPDF extends Fpdi
{
protected $_tplIdx;
protected $is_static_coupon;
public function _set($name, $value){
$this->{$name} = $value;
}
public function Header()
{
if($this->is_static_coupon){
$file = './pdf/coupon/images/coupon-background.pdf';
}else{
$file = './pdf/coupon/images/coupon-background1.pdf';
}
if (null === $this->_tplIdx) {
$this->setSourceFile($file);
$this->_tplIdx = $this->importPage(1);
}
$this->useTemplate($this->_tplIdx);
}
/*function Footer() {
$this->SetFont('Helvetica', '', 10);
$this->SetXY(15, 260);
$this->Cell(180, 0, '', 'T');
$this->Ln();
$this->SetXY(15, 261);
$this->MultiCell(180, 6, utf8_decode($this->_footer_data), 0, 'C');
$this->Ln();
} // end of footer
*/
}