Files
PHPExcel
chart
classes
config
datepicker
html2pdf_v4.03
_class
_tcpdf_5.0.002
examples
res
about.php
bookmark.php
exemple00.php
exemple01.php
exemple02.php
exemple03.php
exemple04.php
exemple05.php
exemple06.php
exemple07.php
exemple08.php
exemple09.php
exemple10.php
exemple11.php
exemple12.php
exemple13.php
forms.php
groups.php
js1.php
js2.php
js3.php
qrcode.php
radius.php
regle.php
svg.php
svg_tiger.php
svg_tree.php
ticket.php
utf8.php
locale
_LGPL.txt
_changelog.txt
_lisez_moi.txt
_read_me.txt
html2pdf.class.php
ul.png
ul2.png
ul3.png
language
lib
overlib
progress
templates
templates_c
admin_bearbeiten.php
config.inc.php
detail_prof.php
detail_prof_pdf.php
erf_besausg.php
erf_besschnitt.php
erf_deltas.php
erf_grundgehalt.php
erf_lb_bz.php
erf_lb_einmal.php
erf_lb_fz.php
erf_lz.php
erf_vza.php
func_LB_BZ.php
func_LB_BZ_fiktiv.php
func_LB_FZ.php
func_LB_FZ_alt.php
func_LB_LZ.php
func_LB_einmal.php
func_LB_obergrenze.php
func_LB_obergrenze_Limit.php
func_LB_obergrenze_Limit_stufe1.php
func_LB_obergrenze_Limit_stufe2.php
func_agent.php
func_besschnitt.php
func_doz_nachbes.php
func_doz_synopse.php
func_genUser.php
func_gesamtberechnung.php
func_grundgehalt.php
func_rollenrechte.php
func_zusammenstellung.php
funktionen_bearbeiten.php
graph_einzeljahr.php
graph_jahre.php
hauptframe.php
index.php
indexframe.php
jahrgang.php
korr_verg.php
load.php
login_log.php
logout.php
lzb_excel.php
menuframe.php
parameter.php
pdf_jahr.php
prof_anlegen.php
prof_bearbeiten.php
prof_bearbeiten.php_20180314
prognose.sql
rollen.php
topframe.php
ubersicht_jahr.php
ubersicht_jahr.php_20180829
user_anlegen.php
user_bearbeiten.php
useronline.php
prognose_kehl/html2pdf_v4.03/examples/groups.php
2023-01-30 08:01:11 +01:00

72 lines
2.0 KiB
PHP
Executable File

<?php
/**
* HTML2PDF Librairy - example
*
* HTML => PDF convertor
* distributed under the LGPL License
*
* @author Laurent MINGUET <webmaster@html2pdf.fr>
*
* isset($_GET['vuehtml']) is not mandatory
* it allow to display the result in the HTML format
*/
ob_start();
?>
<style type="text/css">
<!--
table.page_header {width: 100%; border: none; background-color: #DDDDFF; border-bottom: solid 1mm #AAAADD; padding: 2mm }
table.page_footer {width: 100%; border: none; background-color: #DDDDFF; border-top: solid 1mm #AAAADD; padding: 2mm}
-->
</style>
<page backtop="14mm" backbottom="14mm" backleft="10mm" backright="10mm" pagegroup="new">
<page_header>
<table class="page_header">
<tr>
<td style="width: 100%; text-align: left">
Exemple d'utilisation des groupes de pages
</td>
</tr>
</table>
</page_header>
<page_footer>
<table class="page_footer">
<tr>
<td style="width: 100%; text-align: right">
page [[page_cu]]/[[page_nb]]
</td>
</tr>
</table>
</page_footer>
Ceci est la page 1 du groupe 1
</page>
<page pageset="old">
Ceci est la page 2 du groupe 1
</page>
<page pageset="old">
Ceci est la page 3 du groupe 1
</page>
<?php for ($k=2; $k<5; $k++): ?>
<page pageset="old" pagegroup="new">
Ceci est la page 1 du groupe <?php echo $k; ?>
</page>
<page pageset="old">
Ceci est la page 2 du groupe <?php echo $k; ?>
</page>
<?php endfor; ?>
<?php
$content = ob_get_clean();
require_once(dirname(__FILE__).'/../htdocs2pdf.class.php');
try
{
$html2pdf = new HTML2PDF('P', 'A4', 'fr', true, 'UTF-8', 0);
$html2pdf->pdf->SetDisplayMode('fullpage');
$html2pdf->writeHTML($content, isset($_GET['vuehtml']));
$html2pdf->Output('groups.pdf');
}
catch(HTML2PDF_exception $e) {
echo $e;
exit;
}