当前位置: 首页>>代码示例>>PHP>>正文


PHP mPDF::setFooter方法代码示例

本文整理汇总了PHP中mPDF::setFooter方法的典型用法代码示例。如果您正苦于以下问题:PHP mPDF::setFooter方法的具体用法?PHP mPDF::setFooter怎么用?PHP mPDF::setFooter使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在mPDF的用法示例。


在下文中一共展示了mPDF::setFooter方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: mPDF

        }
    } else {
        $html .= '<' . $e . '>';
    }
}
//==============================================================
//==============================================================
require_once __DIR__ . '/../vendor/autoload.php';
$mpdf = new mPDF('', 'A4', '', '', 32, 25, 27, 25, 16, 13);
$mpdf->SetDirectionality('rtl');
$mpdf->mirrorMargins = true;
$mpdf->SetDisplayMode('fullpage', 'two');
$mpdf->autoLangToFont = true;
$mpdf->defaultPageNumStyle = 'arabic-indic';
$mpdf->setHeader($h);
$mpdf->setFooter($f);
$mpdf->debug = true;
$stylesheet = file_get_contents('mpdfstyletables.css');
$mpdf->WriteHTML($stylesheet, 1);
// The parameter 1 tells that this is css/style only and no body/html/text
$mpdf->WriteHTML($html);
$mpdf->AddPage();
$mpdf->SetColumns(2, 'J');
$mpdf->WriteHTML($html);
$mpdf->SetColumns(0);
//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
// INDEX
$html = '
<pagebreak type="next-odd" />
<h2>Index</h2>
<columns column-count="2" column-gap="5" />
开发者ID:CarlosAyala,项目名称:midas-codeigniter-modulo-emergencias,代码行数:31,代码来源:example26_RTL.php

示例2: mPDF

<?php

$mpdf = new mPDF('', '', 0, '', 10, 10, 16, 16, 9, 26, 'L');
$stylesheet = file_get_contents("../web/css/relatorios-css/relatorio.css");
$mpdf->WriteHTML($stylesheet, 1);
$mpdf->SetTitle($model->titulo);
// Set a simple Footer including the page number
$mpdf->setFooter('<div>Relatório emitido SiGeCentro  <br> {PAGENO}/{nb}</div>');
// Turn off (suppress) page numbering from the start of the document
$mpdf->AddPage('', '', '', '', 'on');
$header = "<div id='cabecalho' >\n        \t\t\t<div id='cabecalho-imagem'>\n        \t\t\t\t<img id='cabecalho-img'   src='" . $model->getImagemLogo() . "'/>\n        \t\t\t</div>\t\n        \t\t\t<div id='cabecalho-titulo' >\n        \t\t\t\t" . $model->titulo . "\n        \t\t\t</div>\n        \t\t\t<div id='cabecalho-emissao'>\n                        <b>SiGeCentro</b>  \n                        <br/>\n        \t\t\t\t<b>Emitido em: " . $model->getDataHora() . "</b>\n\n        \t\t\t</div>\t\n        \t\t</div>\n               <div class='clear'> </div>";
$mpdf->SetHTMLHeader($header, null, true);
$html = "<div id='corpo'>";
for ($i = 1; $i < 400; $i++) {
    $html .= "linha número {$i} | " . $i % 40 . "<br>";
    if ($i % 40 == 0) {
        // realiza quebra de página e adiciona uma nova
        $html .= "</div><pagebreak /><div id='corpo'>";
    }
}
$html .= "</div>";
$mpdf->WriteHTML($html);
$mpdf->Output();
exit;
开发者ID:rsoaresgouveia,项目名称:SiGePolo,代码行数:24,代码来源:relatorio.php

示例3: mPDF

//echo "$query ";

/*
for ($i = 0; $i < $count; $i++) {
     
     echo $html[$i];     
}
*/

//cetak reporting
//$mpdf=new mPDF(); 


$mpdf=new mPDF('','','','',15,15,16,16,9,9,'L');
$mpdf->AddPage('L','','','','',15,15,16,16,9,9);
$mpdf->setFooter('{PAGENO} of 1 pages') ;
$count = count($html);
for ($i = 0; $i < $count; $i++) {
     if($i==0)
          $mpdf->WriteHTML($html[$i]);
     else
     {
           $mpdf->AddPage('L','','','','',15,15,16,16,9,9);
           //$mpdf->AddPage();
           $mpdf->WriteHTML($html[$i]);
           
     }
}


$waktu=date("dymhis");
开发者ID:TrinataBhayanaka,项目名称:simbada-tangsel,代码行数:31,代码来源:report_perencanaan_cetak_dkpbmd.php

示例4: count

//retrieve html
$html=$REPORT->retrieve_html_mutasi_transfer_antar_skpd($result_query, $gambar);

//print html
$count = count($html);
for ($i = 0; $i < $count; $i++) {
    //echo $html[$i];     
}

//cetak reporting
$REPORT->show_status_download_kib();
$mpdf=new mPDF('','','','',15,15,16,16,9,9,'L');
$mpdf->debug=true;
$mpdf->AddPage('L','','','','',15,15,16,16,9,9);
$mpdf->setFooter('{PAGENO}') ;
$mpdf->progbar_heading = '';
$mpdf->StartProgressBarOutput(2);
$mpdf->useGraphs = true;
$mpdf->list_number_suffix = ')';
$mpdf->hyphenate = true;

$count = count($html);
for ($i = 0; $i <= $count; $i++) {
     if($i==0)
          $mpdf->WriteHTML($html[$i]);
     else
     {
           $mpdf->AddPage('L','','','','',15,15,16,16,9,9);
           $mpdf->WriteHTML($html[$i]);
           
开发者ID:TrinataBhayanaka,项目名称:simbada-tangsel,代码行数:29,代码来源:tes_class_mutasi_transfer_antar_skpd.php

示例5: mPDF

<th>TURNO</th>
<th>AREA</th>
<th>DEPARTAMENTO</th>
<th>MEDICAMENTO(S)</th>
<th>FECHA</th><th>PROCESO</th></tr></thead><tbody>' . $tabla . '</tbody></table>';
$html = $tabla;
//==============================================================
//==============================================================
//==============================================================
define('_MPDF_URI', 'data/lib/mpdf60/');
include "data/lib/mpdf60/mpdf.php";
$mpdf = new mPDF('utf-8', 'Leter-L', 0, '', 15, 15, 40, 16, 5, 9);
$mpdf->SetDisplayMode('fullpage');
$mpdf->SetHTMLHeader('
<table style="width: 100%;"><tr><td><h1>Cirpro de Delicias</h1></td><td style="text-align: right"> <img src="img/header.png" style="height 80pt; width: 110pt; margin 0 0 0 0;" alt="Cardinal Healt"></td></tr></table>
<h2>Visitas de ' . $_POST['fecha_inicio_mostrar'] . ' a ' . $_POST['fecha_fin_mostrar'] . ' </h2>
<h4>Reporte de Visitas</h4>');
$mpdf->setFooter('Pagina {PAGENO} de {nbpg}');
$mpdf->list_indent_first_level = 0;
// 1 or 0 - whether to indent the first level of a list
// LOAD a stylesheet
$stylesheet = file_get_contents('mpdfstyletables.css');
$mpdf->WriteHTML($stylesheet, 1);
// The parameter 1 tells that this is css/style only and no body/html/text
$mpdf->WriteHTML($html, 2);
//print $html;
$mpdf->Output('mpdf.pdf', 'I');
exit;
//==============================================================
//==============================================================
//==============================================================
开发者ID:halvgud,项目名称:scproject,代码行数:31,代码来源:pdf_visita_rango_fecha.php

示例6: print_revision_vyrobny_plan

      <link rel="stylesheet" type="text/css" href="assets/css/style.css?1453726010" media="all" />
        <style type="text/css" media="all">
        
      body { font-family: arial; }  
      </style>   
    </head>

    <body class="page">
    <div id="page" class="print ">';
if ($action != "vp_stitky") {
    $prt_revision .= '<img src="http://benab.fotovasko.sk/assets/images/logo.jpg" class="logo">';
}
$prt_revision .= $print_revision;
$prt_revision .= "        \r\n    </div>\r\n\r\n    </body>\r\n    </html>\r\n    ";
if ($action != "vp_stitky") {
    $mpdf->setFooter('{PAGENO} / {nb}');
}
$mpdf->defaultfooterline = 0;
$mpdf->debug = true;
$mpdf->WriteHTML($prt_revision);
$mpdf->Output();
//echo $prt_revision;
exit;
/*
echo $print_revision;
echo "<script type=\"text/javascript\">window.print();</script>";
echo "<div class=\"clearer\"></div>";
*/
//echo "<h2><a href=\"\">späť na revíziu objednávky</a></h2>";
function print_revision_vyrobny_plan($revision, $sub = "")
{
开发者ID:jozefvasko,项目名称:benap-app,代码行数:31,代码来源:print.php

示例7:

</tr></table>
';
$longfooterE = '
<table width="100%" style="border-bottom: 1px solid #000000; vertical-align: bottom; font-family: serif; font-size: 9pt; color: #000088;"><tr>
<td width="33%"><span style="font-weight: bold;">Outer footer</span></td>
<td width="33%" align="center"><img src="sunset.jpg" width="126px" /></td>
<td width="33%" style="text-align: right;">Inner footer p <span style="font-size:14pt;">{PAGENO}</span></td>
</tr></table>
';
$footer = '<div align="center" style="color:blue;font-family:mono;font-size:18pt;font-weight:bold;font-style:italic;">{DATE j-m-Y} &raquo; {PAGENO} &raquo; My document</div>';
$footerE = '<div align="center" style="color:green;font-family:mono;font-size:18pt;font-weight:bold;font-style:italic;">Even page footer - {PAGENO} -</div>';
$shortheader = '<div align="center" style="color:blue;font-family:mono;font-size:18pt;font-weight:bold;font-style:italic;">{DATE j-m-Y} &raquo; {PAGENO} &raquo; My document</div>';
$shortheaderE = '<div align="center" style="color:green;font-family:mono;font-size:18pt;font-weight:bold;font-style:italic;">Even page header - {PAGENO} -</div>';
$mpdf->SetHTMLHeader($header);
$mpdf->SetHTMLHeader($headerE, 'E');
$mpdf->setFooter('{PAGENO} of {nbpg} pages||{PAGENO} of {nbpg} pages');
$mpdf->WriteHTML($html);
$mpdf->setHeader();
// Clear headers before adding page
$mpdf->AddPage('L', '', '', '', '', 25, 25, 55, 45, 18, 12);
$mpdf->SetHTMLHeader($shortheader, '', true);
// New parameter in v1.4 to add the header to the new page
$mpdf->SetHTMLHeader($shortheaderE, 'E', true);
$mpdf->SetHTMLFooter($longfooter);
$mpdf->SetHTMLFooter($longfooterE, 'E');
$mpdf->WriteHTML($html);
$mpdf->WriteHTML($html);
$mpdf->WriteHTML($html);
$mpdf->setHeader('{PAGENO} of {nbpg} pages||{PAGENO} of {nbpg} pages');
$mpdf->SetHTMLFooter($footer);
$mpdf->SetHTMLFooter($footerE, 'E');
开发者ID:dev-lav,项目名称:htdocs,代码行数:31,代码来源:example23_orientation.php

示例8: mpdf_output


//.........这里部分代码省略.........
        if ($pdf_margin_header !== 0 && $pdf_margin_header == '') {
            $pdf_margin_header = 9;
        }
        if ($pdf_margin_footer !== 0 && $pdf_margin_footer == '') {
            $pdf_margin_footer = 9;
        }
        if (empty($pdf_html_header)) {
            $pdf_html_header = false;
        }
        if (empty($pdf_html_footer)) {
            $pdf_html_footer = false;
        }
        global $pdf_orientation;
        if ($pdf_orientation == '') {
            $pdf_orientation = 'P';
        }
        $cp = 'utf-8';
        if (get_option('mpdf_code_page') != '') {
            $cp = get_option('mpdf_code_page');
        }
        $mpdf = new mPDF($cp, 'A4', '', '', $pdf_margin_left, $pdf_margin_right, $pdf_margin_top, $pdf_margin_bottom, $pdf_margin_header, $pdf_margin_footer, $pdf_orientation);
        $mpdf->SetUserRights();
        $mpdf->title2annots = false;
        //$mpdf->annotMargin = 12;
        $mpdf->use_embeddedfonts_1252 = true;
        // false is default
        $mpdf->SetBasePath($templatePath);
        //Set PDF Template if it's set
        global $pdf_template_pdfpage;
        global $pdf_template_pdfpage_page;
        global $pdf_template_pdfdoc;
        if (isset($pdf_template_pdfdoc) && $pdf_template_pdfdoc != '') {
            $mpdf->SetImportUse();
            $mpdf->SetDocTemplate($templatePath . $pdf_template_pdfdoc, true);
        } else {
            if (isset($pdf_template_pdfpage) && $pdf_template_pdfpage != '' && isset($pdf_template_pdfpage_page) && is_numeric($pdf_template_pdfpage_page)) {
                $mpdf->SetImportUse();
                $pagecount = $mpdf->SetSourceFile($templatePath . $pdf_template_pdfpage);
                if ($pdf_template_pdfpage_page < 1) {
                    $pdf_template_pdfpage_page = 1;
                } else {
                    if ($pdf_template_pdfpage_page > $pagecount) {
                        $pdf_template_pdfpage_page = $pagecount;
                    }
                }
                $tplId = $mpdf->ImportPage($pdf_template_pdfpage_page);
                $mpdf->UseTemplate($tplId);
            }
        }
        $user_info = get_userdata($post->post_author);
        $mpdf->SetAuthor($user_info->first_name . ' ' . $user_info->last_name . ' (' . $user_info->user_login . ')');
        $mpdf->SetCreator('wp-mpdf');
        //The Header and Footer
        global $pdf_footer;
        global $pdf_header;
        $mpdf->startPageNums();
        // Required for TOC use after AddPage(), and to use Headers and Footers
        if ($pdf_html_header) {
            $mpdf->SetHTMLHeader($pdf_header);
        } else {
            $mpdf->setHeader($pdf_header);
        }
        if ($pdf_html_footer) {
            $mpdf->SetHTMLFooter($pdf_footer);
        } else {
            $mpdf->setFooter($pdf_footer);
        }
        if (get_option('mpdf_theme') != '' && file_exists($templatePath . get_option('mpdf_theme') . '.css')) {
            //Read the StyleCSS
            $tmpCSS = file_get_contents($templatePath . get_option('mpdf_theme') . '.css');
            $mpdf->WriteHTML($tmpCSS, 1);
        }
        //My Filters
        require_once dirname(__FILE__) . '/myfilters.inc.php';
        $wp_content = mpdf_myfilters($wp_content);
        if (get_option('mpdf_debug') == true) {
            if (!is_dir(dirname(__FILE__) . '/debug/')) {
                mkdir(dirname(__FILE__) . '/debug/');
            }
            file_put_contents(dirname(__FILE__) . '/debug/' . get_option('mpdf_theme') . '_' . $pdf_ofilename . '.html', $wp_content);
        }
        //die($wp_content);
        $mpdf->WriteHTML($wp_content);
        /**
         * Allow to process the pdf by an 3th party plugin
         */
        do_action('mpdf_output', $mpdf, $pdf_filename);
        if (get_option('mpdf_caching') == true) {
            file_put_contents(mpdf_getcachedir() . get_option('mpdf_theme') . '_' . $pdf_ofilename . '.cache', $post->post_modified_gmt);
            $mpdf->Output(mpdf_getcachedir() . get_option('mpdf_theme') . '_' . $pdf_ofilename, 'F');
            if ($outputToBrowser == true) {
                $mpdf->Output($pdf_filename, 'I');
            }
        } else {
            if ($outputToBrowser == true) {
                $mpdf->Output($pdf_filename, 'I');
            }
        }
    }
}
开发者ID:Alinea-Interactive,项目名称:wp-mpdf,代码行数:101,代码来源:wp-mpdf.php

示例9: PrintPDF

 public static function PrintPDF($args)
 {
     $html = $args;
     //$name = $args["name"];
     //$css = $args["css"];
     include "Lib/PDF/mpdf.php";
     $pdf = new mPDF("utf-8");
     $pdf->SetHeader("Lapa");
     $pdf->setFooter("{PAGENO}");
     $pdf->useOnlyCoreFonts = true;
     $pdf->SetDisplayMode("fullpage");
     $pdf->WriteHTML($html);
     $pdf->Output('page.pdf', 'F');
     header("Content-Type: application/force-download");
     header("Content-Type: application/octet-stream");
     header("Content-Type: application/download");
     header("Content-Type: application/pdf");
     header('Content-Disposition: attachment; filename="http://arthurvershinin.id.lv/page.pdf"');
     exit("http://arthurvershinin.id.lv/page.pdf");
 }
开发者ID:arturslukins,项目名称:rvt,代码行数:20,代码来源:system.php

示例10:

//$mpdf->StartProgressBarOutput(1);
$mpdf->SetDisplayMode('fullpage');
$mpdf->defaultfooterline = 0;
$mpdf->SetHTMLHeader('
<table style="width: 100%;"><tr><td><h1>Cirpro de Delicias</h1></td><td style="text-align: right"> <img src="img/header.png" style="height 80pt; width: 110pt; margin 0 0 0 0;" alt="Cardinal Healt"></td></tr></table>
<h2>Memos de ' . $_POST['fecha_inicio_mostrar'] . ' a ' . $_POST['fecha_fin_mostrar'] . ' </h2>
<h3>AT¨N DEPARTAMENTO DE NOMINAS</h3>
<p>Por medio de la presente se le solicita, que a las siguientes personas les sea respetado lo que a continuación se menciona:</p>
<p STYLE="text-align:right;">BONOS DE PUNTUALIDAD Y ASISTENCIA</p>
');
$mpdf->setFooter('
<table>
<tr><td>___________________________________</td><td></td><td>______________________________________________</td><td></td><td>___________________________________</td></tr>
<tr><td style="text-align: center; ">Relaciones Laborales</td>
<td style="text-align: center;padding-left: 20mm; padding-right: 20mm; "></td>
<td style="text-align: center;">GTE. DE REC. HUMANOS</td>
<td style="text-align: center;padding-left: 20mm; padding-right: 20mm; "></td>
<td style="text-align: center; ">Gte. Finanzas</td></tr>
</table>
<BR>
Pagina {PAGENO} de {nbpg}');
$mpdf->list_indent_first_level = 0;
// 1 or 0 - whether to indent the first level of a list
// LOAD a stylesheet
$stylesheet = file_get_contents('mpdfstyletables.css');
$mpdf->WriteHTML($stylesheet, 1);
// The parameter 1 tells that this is css/style only and no body/html/text
$mpdf->WriteHTML($html, 2);
//print $html;
$mpdf->Output($NomrePDF, 'I');
exit;
开发者ID:halvgud,项目名称:scproject,代码行数:31,代码来源:pdf_memo_rango_fecha.php

示例11: gerar

 public static function gerar()
 {
     $template = $_GET['template'];
     $css = is_file('util/rel_templates/' . $template . ".css") ? 'util/rel_templates/' . $template . ".css" : 'util/rel_templates/mpdfstyletables.css';
     if (!isset($_GET['dados'])) {
         $classe = $_GET['classe'];
         $metodo = $_GET['metodo'];
         $parametros = $_GET['parametros'];
         $dados = call_user_func_array(array(new $classe(), $metodo), $parametros);
     } else {
         $dados = $_GET['dados'];
     }
     $html = self::getHtmlTemplate("util/rel_templates/" . $template . ".php", $dados);
     $mpdf = new mpdf();
     $papel = isset($_GET['papel']) ? $_GET['papel'] : 'A4';
     $mpdf = new mPDF('c', $papel, '', '', 5, 5, 15, 5, 5, 5);
     //$mpdf->use_kwt = true ;
     //$mpdf->list_indent_first_level = 0;
     $stylesheet = file_get_contents($css);
     $mpdf->WriteHTML($stylesheet, 1);
     $mpdf->WriteHTML($hhtml, 2);
     $mpdf->setFooter('{PAGENO} of {nbpg} pages||{PAGENO} of {nbpg} pages');
     $mpdf->WriteHTML($html, 2);
     $mpdf->Output("relatorio.pdf", 'I');
 }
开发者ID:filipecoelho,项目名称:webliniaerp-api,代码行数:25,代码来源:RelatorioPDF.php


注:本文中的mPDF::setFooter方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。