本文整理汇总了PHP中PDF::Image方法的典型用法代码示例。如果您正苦于以下问题:PHP PDF::Image方法的具体用法?PHP PDF::Image怎么用?PHP PDF::Image使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PDF
的用法示例。
在下文中一共展示了PDF::Image方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: createPDF_overall
public static function createPDF_overall($reportDetails, $AnalysisData)
{
$pdf = new PDF();
$pdf->SetLeftMargin(25);
$pdf->AddPage();
$pdf->SetFont('Arial', 'B', 16);
$pdf->Cell(0, 15, 'Students Overall Report', 0, 0, "C");
$pdf->Ln(25);
$pdf->reportData($reportDetails);
$pdf->Ln(10);
$pdf->makeTable($AnalysisData);
$pdf->Image('../../mod/graph/barChart.png', 60, 150, 90);
// $pdf->Image('../../mod/graph/3DpieChart.png',120,160,70);
$pdf->Ln(80);
$pdf->SetFont('Arial', 'B', 11);
$pdf->Cell(0, 5, 'Assignment Progress', 0, 0, "L");
$pdf->Ln(10);
$pdf->SetFont('Arial', '', 9);
$pdf->Write(5, "Students all assignment marks evaluating for this subject is shown blow..!! This is help to evaluate progress of whole batch..!!!!!! ");
$pdf->AddPage();
$pdf->SetFont('Arial', 'B', 11);
$pdf->Cell(0, 5, 'Results Compare with Last year', 0, 0, "L");
$pdf->Ln(5);
$pdf->Image('../../mod/graph/compareLineChart.png', 40, 20, 130);
unlink('../../mod/graph/3DpieChart.png');
unlink('../../mod/graph/barChart.png');
unlink('../../mod/graph/compareLineChart.png');
$pdf->Output("Report.pdf", "I");
}
示例2: render
/**
* PDF image renderer
*
* @param PDF $pdf
*
* @return void
*/
function render($pdf)
{
global $lastpicbottom, $lastpicpage, $lastpicleft, $lastpicright;
// Check for a pagebreak first
if ($pdf->checkPageBreakPDF($this->height + 5)) {
$this->y = $pdf->GetY();
}
$curx = $pdf->GetX();
// If current position (left)set "."
if ($this->x == ".") {
$this->x = $pdf->GetX();
} else {
$this->x = $pdf->addMarginX($this->x);
$pdf->SetX($curx);
}
if ($this->y == ".") {
//-- first check for a collision with the last picture
if (isset($lastpicbottom)) {
if ($pdf->PageNo() == $lastpicpage && $lastpicbottom >= $pdf->GetY() && $this->x >= $lastpicleft && $this->x <= $lastpicright) {
$pdf->SetY($lastpicbottom + 5);
}
}
$this->y = $pdf->GetY();
} else {
$pdf->SetY($this->y);
}
if ($pdf->getRTL()) {
$pdf->Image($this->file, $pdf->getPageWidth() - $this->x, $this->y, $this->width, $this->height, "", "", $this->line, false, 72, $this->align);
} else {
$pdf->Image($this->file, $this->x, $this->y, $this->width, $this->height, "", "", $this->line, false, 72, $this->align);
}
$lastpicpage = $pdf->PageNo();
$pdf->lastpicpage = $pdf->getPage();
$lastpicleft = $this->x;
$lastpicright = $this->x + $this->width;
$lastpicbottom = $this->y + $this->height;
// Setup for the next line
if ($this->line == "N") {
$pdf->SetY($lastpicbottom);
}
}
示例3: explode
$image = $_POST['image'];
$clues = explode(',', $_POST['clues']);
require 'MultiCellBlt2.php';
//Create pdf
$pdf = new PDF();
$pdf->AddPage();
//set document properties
$pdf->SetAuthor('Anon');
$pdf->SetTitle($name);
// Set the page break to 'true' and the bottom margin height
$pdf->SetAutoPageBreak(1, 10);
//set font for the entire document
$pdf->SetFont('Helvetica', 'B', 20);
$pdf->SetTextColor(50, 60, 100);
//insert Collage logo
$pdf->Image('logo.png', 10, 10, 33, 0);
//display the title without a border around it
$pdf->SetXY(50, 15);
$pdf->SetDrawColor(50, 60, 100);
$pdf->Cell(100, 10, $name, 0, 0, 'C', 0);
// Insert a dynamic image from a URL
$pdf->Image($image, 11, 30, 0, 50);
//Set x and y position for the main text, reduce font size and write content
$pdf->SetXY(65, 30);
$pdf->SetLeftMargin(65);
$pdf->SetFontSize(10);
$pdf->Write(5, $characteristics);
$pdf->Ln(8);
//Output the clues
$pdf->SetFont('Helvetica', '', 9);
$pdf->SetXY(10, 90);
示例4:
//RETRIEVED DATA JNG
$order_data = $class_o->retrieveDetail($order_id);
$items = $class_o->retrieveProducts($order_id);
$order['id'] = $order_data['orders_no'];
$order['customer'] = $order_data['delivery_name'];
$order['prefix_code'] = '';
}
if ($order_counter % $pdf->label_per_page == 0) {
$pdf->AddPage();
}
$order_counter++;
$xpos_starter = ($labelxpos - 1) * $pdf->label_width + $labelxpad;
$ypos_starter = ($labelypos - 1) * $pdf->label_height + $labelypad;
$logo_xpos = $xpos_starter + 52;
$logo_ypos = $ypos_starter;
$pdf->Image(FPDF_IMGPATH . 'jng-logo.png', $logo_xpos, $logo_ypos, 43, 5.33);
//WxH 64.5 x 8
$xpos = $xpos_starter;
$ypos = $ypos_starter - 2;
//NUMBERING
$pdf->SetXY($xpos, $ypos);
$pdf->setFont('Arial', 'B', '18');
$pdf->Cell(10, 10, $order_counter);
//SP FLAG
if ($order['prefix_code'] != '') {
$pdf->SetXY($xpos + 76, $ypos + 5);
$pdf->setFont('Arial', '', '10');
$pdf->Cell(20, 10, $order['prefix_code'], '0', '0', 'R');
}
//ORDER DETAIL
$pdf->setFont('Arial', '', '12');
示例5: explode
$pdf->SetFont('arial', '', $sizetitre);
$pdf->RotatedCell($angle, $xtitre, $ytitre, $wtitre, $htitre, $_GET['titre'], 0, 0, 'C');
$pdf->RotatedText(15, 15, $titre, 0);
$pdf->SetFont('arial', '', $sizeechelle);
if ($_GET['echelle'] == 0) {
$pdf->RotatedText($posixechelle, $posiyechelle, 'Sans échelle', $angle);
} else {
$pdf->RotatedText($posixechelle, $posiyechelle, '1/' . $_GET['echelle'] . ' ème', $angle);
}
if ($print_basic_copyright) {
$pdf->SetFont('arial', '', 6);
$pdf->RotatedText(5, 5, "Les photographies sont propriétées de l'IGN, les données cadastrales sont propriétées de la DGI. Reproduction interdite.", 0);
}
//génération du qrcode;
$url_qrcode = "https://" . $_SERVER["HTTP_HOST"] . "/interface/qrprint.php?var=" . $application . "\$" . $_GET['x'] . "\$" . $_GET['y'] . "\$" . $_GET['lar'] . "\$" . $_GET['hau'] . "\$" . $_GET['zoom'] . "\$" . $_GET['format'] . "\$" . $_GET['legende'] . "\$" . $_GET['titre'] . "\$" . $_GET['echelle'] . "\$" . $_GET['parce'] . "\$" . $_GET['raster'];
$pdf->Image(generateQRCode($url_qrcode, 100), $xqrcode, $yqrcode, 30, 30, 'PNG');
$pdf->SetDrawColor(0);
$pdf->SetFont('arial', '', 10);
if ($_GET['legende'] == 1 || $_GET['legende'] == 3) {
$legende = "";
//$pyy=250;
$idprov = "";
for ($i = 0; $i < count($rastx); $i++) {
$ra = explode(".", $rastx[$i]);
$id = $ra[0];
$lib = str_replace("_", " ", $ra[1]);
if ($id != "") {
$req1 = "select col_theme.intitule_legende as intitule_legende,theme.libelle_them,col_theme.fill,col_theme.symbole,col_theme.opacity,col_theme.ordre,col_theme.stroke_rgb,style.fill as style_fill,style.symbole as style_symbole,style.opacity as style_opacity,style.font_size as style_fontsize,style.stroke_rgb as style_stroke from admin_svg.appthe left outer join admin_svg.col_theme on appthe.idappthe=col_theme.idappthe join admin_svg.theme on appthe.idtheme=theme.idtheme left outer join admin_svg.style on appthe.idtheme=style.idtheme where appthe.idappthe='" . $id . "' and (intitule_legende='" . $lib . "' or libelle_them='" . $lib . "')";
$couch = $DB->tab_result($req1);
if ($couch[0]['intitule_legende'] == "") {
$legend = $couch[0]['libelle_them'];
示例6: Footer
$fecha = vacunacionTableClass::FECHA;
$animal = animalTableClass::NUMERO;
$veterinario = veterinarioTableClass::NOMBRE;
class PDf extends FPDF
{
function Footer()
{
$this->SetY(-15);
$this->SetFont('Arial', 'I', 8);
$this->Cell(0, 10, 'Page ' . $this->PageNo() . '/{nb}', 0, 0, 'C');
}
}
$pdf = new PDF('P', 'mm', 'letter');
$pdf->AliasNbPages();
$pdf->AddPage();
$pdf->Image(routing::getInstance()->getUrlImg('reporte_Vertical.jpg'), 0, 0, 216, 280);
$pdf->Ln(40);
$pdf->SetFont('Arial', 'B', 25);
$pdf->Cell(93);
$pdf->Cell(30, 10, $mensaje, 0, 0, 'C');
$pdf->Ln(20);
$pdf->SetFont('Arial', 'B', 15);
$pdf->Cell(10);
//$pdf->Cell(37, 10, utf8_decode('N. Documento'), 1, 0, 'C');
$pdf->Cell(40, 10, utf8_decode('Fecha'), 1, 0, 'C');
$pdf->Cell(38, 10, utf8_decode('Animal'), 1, 0, 'C');
$pdf->Cell(100, 10, utf8_decode('Veterinario'), 1, 0, 'C');
$pdf->Ln();
foreach ($objVacunacion as $key) {
$pdf->Cell(10);
// $pdf->Cell(37, 10, utf8_decode($key->id), 1);
示例7: PutLink
function PutLink($URL, $txt)
{
// Put a hyperlink
$this->SetTextColor(0, 0, 255);
$this->SetStyle('U', true);
$this->Write(5, $txt, $URL);
$this->SetStyle('U', false);
$this->SetTextColor(0);
}
}
$datArray = array();
$html = 'You can now easily print text mixing different styles: <b>bold</b>, <i>italic</i>,
<u>underlined</u>, or <b><i><u>all at once</u></i></b>!<br><br>You can also insert links on
text, such as <a href="http://www.fpdf.org">www.fpdf.org</a>, or on an image: click on the logo.';
$pdf = new PDF();
// First page
$pdf->AddPage();
$pdf->SetFont('Arial', '', 20);
$pdf->Write(5, "To find out what's new in this tutorial, click ");
$pdf->SetFont('', 'U');
$link = $pdf->AddLink();
$pdf->Write(5, 'here', $datArray[0]);
$pdf->SetFont('');
// Second page
$pdf->AddPage();
$pdf->SetLink($datArray[0]);
$pdf->Image('../img/intro-bg.jpg', 10, 12, 30, 0, '', 'http://www.fpdf.org');
$pdf->SetLeftMargin(45);
$pdf->SetFontSize(14);
$pdf->WriteHTML($html);
$pdf->Output();
示例8: PDF
break;
case "12":
$mes = "DICIEMBRE";
break;
}
return "MAZATLAN SINALOA ".date("d")." DE ".$mes." DE ".date("Y")."";
}
}
$pdf = new PDF();
//$pdf -> AliasNbPages();
$pdf -> AddPage();
//INFORMACION GENERAL
$pdf -> Image('cab2_informacion_general.jpg',10,42,180);
$pdf -> addLeyenda("Nombre o Razón Social: ".$f->nombrecliente."",50);
$pdf -> agregarLinea(166,243,140,10);
$pdf -> addLeyenda("Giro: ".$f->giro."",55);
$pdf -> agregarLinea(192,238,65,10);
$pdf -> addLeyenda2("R.F.C.: ".$f->rfc."",55,85);
$pdf -> agregarLinea(114,238,30,10);
$pdf -> addLeyenda2("Antigüedad: ".$f->antiguedad."",55,130);
$pdf -> agregarLinea(62,238,36,10);
$pdf -> addLeyenda("DOMICILIO FISCAL",60);
$pdf -> addLeyenda("Calle: ".$f->calle."",65);
$pdf -> agregarLinea(191,228,100,10);
$pdf -> addLeyenda2("No. Ext.: ".$f->numero."",65,120);
$pdf -> agregarLinea(77,228,51,10);
$pdf -> addLeyenda("Colonia: ".$f->colonia."",70);
$pdf -> agregarLinea(187,223,161,10);
示例9: PDF
return "N/A";
} else {
if ($data >= 10000) {
$data = number_format($data);
}
return $json[$themeasure]["style"]["prefix"] . $data . $json[$themeasure]["style"]["units"];
}
}
// Create PDF
$pdf = new PDF('P', 'in', 'Letter');
/************************************************************
Cover Page
************************************************************/
$pdf->AddPage();
// title page image background
$pdf->Image('reportCoverPageCompass.png', 0, 0, 8.5);
// White text on top of title page
// $pdf->SetTextColor(255,255,255);
// Title page header
$pdf->SetTextColor(0, 0, 45);
$pdf->SetFont('Arial', 'B', 50);
$pdf->Ln(5.35);
$pdf->Cell(0.3);
$pdf->Cell(0, 0, "Compass Profile Area");
if ($reportRadioValue == 'census') {
$pdf->SetTextColor(0, 0, 45);
$pdf->SetFont('Arial', 'B', 40);
$pdf->Ln(1);
// $aryPrettyBlock = explode(" - ", $censusBlock);
// $prettyBlock = $aryPrettyBlock[1];
$pdf->Cell(0.3);
示例10: addSticker
/**
* Output a sticker on page at position _COUNTX, _COUNTY (_COUNTX and _COUNTY start from 0)
*
* @param PDF $pdf PDF reference
* @param Translate $outputlangs Output langs
* @param array $param Associative array containing label content and optional parameters
* @return void
*/
function addSticker(&$pdf, $outputlangs, $param)
{
global $mysoc, $conf;
$textleft = $param['textleft'];
$header = $param['textheader'];
$footer = $param['textfooter'];
$textright = $param['textright'];
$code = $param['code'];
$encoding = $param['encoding'];
$is2d = $param['is2d'];
// We are in a new page, then we must add a page
if ($this->_COUNTX == 0 && $this->_COUNTY == 0 and !$this->_First == 1) {
$pdf->AddPage();
}
$this->_First = 0;
$_PosX = $this->_Margin_Left + $this->_COUNTX * ($this->_Width + $this->_X_Space);
$_PosY = $this->_Margin_Top + $this->_COUNTY * ($this->_Height + $this->_Y_Space);
// Define logo
$logo = $conf->mycompany->dir_output . '/logos/' . $mysoc->logo;
if (!is_readable($logo)) {
$logo = '';
if (!empty($mysoc->logo_small) && is_readable($conf->mycompany->dir_output . '/logos/thumbs/' . $mysoc->logo_small)) {
$logo = $conf->mycompany->dir_output . '/logos/thumbs/' . $mysoc->logo_small;
} elseif (!empty($mysoc->logo) && is_readable($conf->mycompany->dir_output . '/logos/' . $mysoc->logo)) {
$logo = $conf->mycompany->dir_output . '/logos/' . $mysoc->logo;
}
}
$xleft = 2;
$ytop = 2;
// Top
if ($header != '') {
$pdf->SetXY($_PosX + $xleft, $_PosY + 1);
// Only 1 mm and not ytop for top text
$pdf->Cell($this->_Width - 2 * $xleft, $this->_Line_Height, $outputlangs->convToOutputCharset($header), 0, 1, 'C');
}
$ytop += empty($header) ? 0 : 1 + $this->_Line_Height;
// Define widthtouse and heighttouse
$pageMargins = $pdf->getMargins();
$maxwidthtouse = round($this->_Width - 2 * $xleft);
$maxheighttouse = round($this->_Height - 2 * $ytop);
$maxheighttouse -= empty($footer) ? 0 : 1 + $this->_Line_Height;
$defaultratio = $maxwidthtouse / $maxheighttouse;
$widthtouse = $maxwidthtouse;
$heighttouse = $maxheighttouse;
$logoHeight = $heighttouse;
$logoWidth = $heighttouse;
//var_dump($this->_Width.'x'.$this->_Height.' with border and scale '.$imgscale.' => max '.$maxwidthtouse.'x'.$maxheighttouse.' => We use '.$widthtouse.'x'.$heighttouse);exit;
// Center
if ($textright == '') {
// Output left area
if ($textleft == '%LOGO%' && $logo) {
$pdf->Image($logo, $_PosX + $xleft, $_PosY + $ytop, 0, $logoHeight);
} else {
if ($code && !empty($encoding)) {
$this->writeBarcode($pdf, $code, $encoding, $is2d, $_PosX + $xleft, $_PosY + $ytop, $widthtouse, $heighttouse);
} else {
$pdf->SetXY($_PosX + $xleft, $_PosY + $ytop);
$pdf->MultiCell($this->_Width, $this->_Line_Height, $outputlangs->convToOutputCharset($textleft), 0, 'L');
}
}
} else {
if ($textleft != '' && $textright != '') {
if (($textleft == '%LOGO%' || $textleft == '%PHOTO%' || $textleft == '%BARCODE%') && !strstr($textright, '%')) {
if ($textleft == '%LOGO%' && $logo) {
$pdf->Image($logo, $_PosX + $xleft, $_PosY + $ytop, $widthtouse / 2, 0);
} else {
if ($code && !empty($encoding)) {
$this->writeBarcode($pdf, $code, $encoding, $is2d, $_PosX + $xleft, $_PosY + $ytop, $widthtouse / 2, $heighttouse);
}
}
$pdf->SetXY($_PosX + $widthtouse / 2, $_PosY + $ytop);
$pdf->MultiCell($widthtouse / 2, $this->_Line_Height, $outputlangs->convToOutputCharset($textright), 0, 'R');
} else {
if (($textright == '%LOGO%' || $textright == '%PHOTO%' || $textright == '%BARCODE%') && !strstr($textleft, '%')) {
if ($textright == '%LOGO%' && $logo) {
$pdf->Image($logo, $_PosX + $widthtouse / 2, $_PosY + $ytop, $widthtouse / 2, 0);
} else {
if ($code && !empty($encoding)) {
$this->writeBarcode($pdf, $code, $encoding, $is2d, $_PosX + $widthtouse / 2, $_PosY + $ytop, $widthtouse / 2, $heighttouse);
}
}
$pdf->SetXY($_PosX + $xleft, $_PosY + $ytop);
$pdf->MultiCell($widthtouse / 2, $this->_Line_Height, $outputlangs->convToOutputCharset($textleft), 0, 'L');
} else {
if ($textleft == '%LOGO%') {
if ($logo) {
$pdf->Image($logo, $_PosX + $xleft, $_PosY + $ytop, 0, $logoHeight);
}
if ($code && !empty($encoding)) {
$this->writeBarcode($pdf, $code, $encoding, $is2d, $_PosX + $xleft + $logoWidth + 1, $_PosY + $ytop, $widthtouse - $logoWidth - 1, $heighttouse);
} else {
$pdf->SetXY($_PosX + $xleft + $logoWidth + 1, $_PosY + $ytop);
//.........这里部分代码省略.........
示例11:
$b9 = $row5['b9'];
$b10 = $row5['b10'];
$b11 = $row5['b11'];
$b12 = $row5['b12'];
$b13 = $row5['b13'];
$b14 = $row5['b14'];
$b15 = $row5['b15'];
$b16 = $row5['b16'];
$b17 = $row5['b17'];
$b18 = $row5['b18'];
$b19 = $row5['b19'];
$b20 = $row5['b20'];
$encabezamiento = 'PLAN DE TRABAJO INDIVIDUALIZADO' . "\n" . '(Decreto 69/2007,Artículo 10)' . "\n" . 'MATERIA: ' . $materia2;
$pdf->AddPage();
$pdf->SetFont('Arial', 'B', 12);
$pdf->Image('logoclm.jpg', 10, 10);
$pdf->SetLineWidth(0.5);
$pdf->Cell(50, 10, '');
$pdf->SetFillColor(150, 150, 150);
$pdf->Multicell(90, 8, $encabezamiento, 1, 'C', 1, 1);
$pdf->SETXY(10, 50);
$pdf->SetFont('Arial', 'B', 10);
$pdf->Multicell(160, 5, 'PERFIL ACADÉMICO DEL ALUMNO. GRUPO:' . $grupo . "\n", 1, 'C', 1);
$pdf->SetFont('Arial', '', 8);
$pdf->SETXY(10, 55);
$pdf->Multicell(80, 5, 'ALUMNO: ' . $nombre2 . "\n" . 'CURSO: ' . $curso2 . "\n" . 'TUTOR/-A: ' . $tutor2, 1);
$pdf->SETXY(90, 55);
$pdf->Multicell(80, 5, 'MATERIA: ' . $materia2 . "\n" . 'CALIFICACIÓN: ' . $calificacion2 . "\n" . 'PROFESOR/-A: ' . $profesor2, 1);
$perfilacademico = "";
if ($acnee2 == 1) {
$perfilacademico = $perfilacademico . "El alumno es ACNEE.\n";
示例12: date
} else {
$year = date('y');
}
$codigo = $year . '-' . str_pad($curso_id, 4, "0", STR_PAD_LEFT) . '-' . str_pad($id, 4, "0", STR_PAD_LEFT);
//IDIOMA DEL CURSO
$idioma = pg_result($curso, 0, 'idioma');
//echo $idioma;
include 'includes/internacionalizacion.php';
if ($edicion == 'OFF' && $est == 'APR' && $est_admin == 'ON') {
$pdf = new PDF("P", "cm", "A4");
$pdf->AddPage();
//define("FPDF_FONTPATH", "/usr/share/fonts/truetype/ttf-dejavu");
$pdf->AddFont('DejaVu', '', 'DejaVuSansCondensed.ttf', true);
if ($curso_id == 36) {
//Imagen de Coopeciagro Gustavo Aguero
$pdf->Image('img/certificados/certificado-firmado-sellado-training_coopeciagro.jpg', 0, 0, 21, 29.7);
} elseif ($curso_id == 214) {
//Curso Presencial en Nicaragua dictado por Jose Campos de Gustavo Aguero
$pdf->Image('img/certificados/certificado-firmado-sellado-training_gustavo3.jpg', 0, 0, 21, 29.7);
} elseif ($curso_id == 258 || $curso_id == 290) {
//Curso GISMAP WEBMINAR
$pdf->Image('img/certificados/certificado-GISMAP-WEBMINAR.jpg', 0, 0, 21, 29.7);
} elseif ($curso_id == 243) {
//Segundo Curso en Nicaragua Nivel Intermedio dictado por Gustavo Aguero
$pdf->Image('img/certificados/certificado-firmado-sellado-training_gustavo4.jpg', 0, 0, 21, 29.7);
} elseif ($curso_id == 241) {
//Fundacion Tripartita
$pdf->Image('img/certificados/certificado_tripartita.jpg', 0, 0, 21, 29.7);
} elseif ($curso_id == 40) {
//Coopeciagre 2 Gustavo Aguero
$pdf->Image('img/certificados/certificado-firmado-sellado-training_coopeciagro2.jpg', 0, 0, 21, 29.7);
示例13: pdf_pagehead
/**
* Show header of page for PDF generation
*
* @param PDF $pdf Object PDF
* @param Translate $outputlangs Object lang for output
* @param int $page_height Height of page
* @return void
*/
function pdf_pagehead(&$pdf, $outputlangs, $page_height)
{
global $conf;
// Add a background image on document
if (!empty($conf->global->MAIN_USE_BACKGROUND_ON_PDF)) {
$pdf->SetAutoPageBreak(0, 0);
// Disable auto pagebreak before adding image
$pdf->Image($conf->mycompany->dir_output . '/logos/' . $conf->global->MAIN_USE_BACKGROUND_ON_PDF, isset($conf->global->MAIN_USE_BACKGROUND_ON_PDF_X) ? $conf->global->MAIN_USE_BACKGROUND_ON_PDF_X : 0, isset($conf->global->MAIN_USE_BACKGROUND_ON_PDF_Y) ? $conf->global->MAIN_USE_BACKGROUND_ON_PDF_Y : 0, 0, $page_height);
$pdf->SetAutoPageBreak(1, 0);
// Restore pagebreak
}
}
示例14:
$pdf->SetFont('Arial', 'BU', 14);
$pdf->SetTextColor(70, 125, 25);
$pdf->Cell(0, 10, 'CHECK FOTOGRAFICO DE LA VIVIENDA Y ALREDEDORES', 0, 1, 'C');
$pdf->SetTextColor(0, 0, 0);
$pdf->Ln(2);
$pdf->SetTextColor(0, 0, 0);
$pdf->SetFont('Arial', 'B', 12);
$pdf->Cell(55, 7, 'NOMBRES Y APELLIDOS', 1, 0, 'L');
$pdf->SetFont('Arial', '', 12);
$pdf->Cell(0, 7, $nombre, 1, 1, 'C');
$pdf->SetFont('Arial', 'B', 12);
$pdf->Cell(55, 7, 'DIRECCION', 1, 0, 'L');
$pdf->SetFont('Arial', '', 12);
$pdf->MultiCell(0, 7, $domicilio, 1, 'C');
$pdf->Ln(5);
$pdf->Image("../files/images_dom/{$fotos['0']}", 40, null, 130, 100);
$pdf->Ln(2);
$pdf->Image("../files/images_dom/{$fotos['1']}", 40, null, 130, 100);
$pdf->Ln(2);
$pdf->AddPage();
$pdf->SetXY(20, 25);
$pdf->SetFont('Arial', 'BU', 14);
$pdf->SetTextColor(70, 125, 25);
$pdf->Cell(0, 10, 'MAPA DE ZONIFICACION - CHECK DOMICILIARIO', 0, 1, 'C');
$pdf->SetTextColor(0, 0, 0);
$pdf->Ln(2);
$pdf->SetTextColor(0, 0, 0);
$pdf->SetFont('Arial', 'B', 12);
$pdf->Cell(55, 7, 'NOMBRES Y APELLIDOS', 1, 0, 'L');
$pdf->SetFont('Arial', '', 12);
$pdf->Cell(0, 7, $nombre, 1, 1, 'C');
示例15: CONCAT
// con filtro del departemento
if ($depto != '-1' and $motivo == '-1' and ($fechai != "" and $fechaf != "")) {
$query1 = " \nSelect empleado.No_Empleado, CONCAT(Primer_nombre, ' ', Segundo_nombre, ' ', Primer_apellido, ' ', Segundo_Apellido) as Nombre, departamento_laboral.nombre_departamento,motivos.descripcion, \nCOUNT(permisos.id_Permisos) as Solicitudes, SUM(permisos.dias_permiso) as Inasistencias from permisos\n inner join motivos on permisos.id_motivo=motivos.Motivo_ID \n inner join empleado on empleado.No_Empleado=permisos.No_Empleado \n inner join persona on persona.N_identidad=empleado.N_identidad \n inner join departamento_laboral on departamento_laboral.id_departamento_laboral = permisos.id_departamento \n where departamento_laboral.nombre_departamento='" . $depto . "'\n and date_format(permisos.fecha,'%d-%m-%Y') between date_format('" . $fechai . " ','%d-%m-%Y')and date_format('" . $fechaf . "','%d-%m-%Y')\t\n\tGROUP BY Primer_nombre, Segundo_nombre, Primer_apellido, Segundo_Apellido, departamento_laboral.nombre_departamento ORDER BY Primer_nombre asc";
}
// con filtro del motivos y depattamento
if ($depto != '-1' and $motivo != '-1' and ($fechai != "" and $fechaf != "")) {
$query1 = " \nSelect empleado.No_Empleado, CONCAT(Primer_nombre, ' ', Segundo_nombre, ' ', Primer_apellido, ' ', Segundo_Apellido) as Nombre, departamento_laboral.nombre_departamento,motivos.descripcion, \nCOUNT(permisos.id_Permisos) as Solicitudes, SUM(permisos.dias_permiso) as Inasistencias from permisos\n inner join motivos on permisos.id_motivo=motivos.Motivo_ID \n inner join empleado on empleado.No_Empleado=permisos.No_Empleado \n inner join persona on persona.N_identidad=empleado.N_identidad \n inner join departamento_laboral on departamento_laboral.id_departamento_laboral = permisos.id_departamento \n where departamento_laboral.nombre_departamento='" . $depto . "' and motivos.descripcion='" . $motivo . "' and \n date_format(permisos.fecha,'%d-%m-%Y') between date_format('" . $fechai . " ','%d-%m-%Y')and date_format('" . $fechaf . "','%d-%m-%Y')\t\n\tGROUP BY Primer_nombre, Segundo_nombre, Primer_apellido, Segundo_Apellido, departamento_laboral.nombre_departamento,motivos.descripcion ORDER BY Primer_nombre asc";
}
// por fechas
if ($depto == '-1' and $motivo != '-1') {
$query1 = " \nSelect empleado.No_Empleado, CONCAT(Primer_nombre, ' ', Segundo_nombre, ' ', Primer_apellido, ' ', Segundo_Apellido) as Nombre, departamento_laboral.nombre_departamento, motivos.descripcion, \nCOUNT(permisos.id_Permisos) as Solicitudes, SUM(permisos.dias_permiso) as Inasistencias from permisos\n inner join motivos on permisos.id_motivo=motivos.Motivo_ID \n inner join empleado on empleado.No_Empleado=permisos.No_Empleado \n inner join persona on persona.N_identidad=empleado.N_identidad \n inner join departamento_laboral on departamento_laboral.id_departamento_laboral = permisos.id_departamento \n where motivos.descripcion='" . $motivo . "' and \n date_format(permisos.fecha,'%d-%m-%Y') between date_format('" . $fechai . " ','%d-%m-%Y')and date_format('" . $fechaf . "','%d-%m-%Y')\t\n\tGROUP BY Primer_nombre, Segundo_nombre, Primer_apellido, Segundo_Apellido, departamento_laboral.nombre_departamento,motivos.descripcion ORDER BY Primer_nombre asc";
}
$pdf = new PDF();
$pdf->AddPage("L", "Letter");
$pdf->SetFont('Arial', '', 18);
$pdf->Image($maindir . 'assets/img/lucen-aspicio.png', 50, 15, 200, 200, 'PNG');
$pdf->Image($maindir . 'assets/img/logo_unah.png', 15, 5, 24, 36, 'PNG');
$pdf->Image($maindir . 'assets/img/logo-cienciasjuridicas.png', 230, 8, 35, 35, 'PNG');
$pdf->Cell(22, 10, '', 0);
$pdf->SetFont('Arial', '', 18);
$pdf->Cell(45, 10, '', 0);
$pdf->Cell(70, 10, utf8_decode('Universidad Nacional Autónoma de Honduras'), 0);
$pdf->Ln(10);
$pdf->SetFont('Arial', 'U', 14);
$pdf->Cell(60, 8, '', 0, 0, "C");
$pdf->Cell(130, 8, 'Reportes de Permisos Personales', 0, 0, "C");
$pdf->Ln(25);
//$pdf->AddCol('N',25,'#Empleado','C');
$pdf->AddCol('Nombre', 70, 'Nombre Completo', 'C');
$pdf->AddCol('nombre_departamento', 40, 'Departamento', 'C');
$pdf->AddCol('descripcion', 40, 'Motivo', 'C');