mirror of
https://github.com/wallabag/wallabag.git
synced 2025-08-01 17:38:38 +00:00
add pdf and mobi libraries
This commit is contained in:
parent
2b58426b2d
commit
4188f38ad5
297 changed files with 126557 additions and 7 deletions
36
inc/3rdparty/libraries/mpdf/examples/example41_MPDFI_template.php
vendored
Normal file
36
inc/3rdparty/libraries/mpdf/examples/example41_MPDFI_template.php
vendored
Normal file
|
@ -0,0 +1,36 @@
|
|||
<?php
|
||||
|
||||
include("../mpdf.php");
|
||||
|
||||
$mpdf=new mPDF('','','','',15,15,57,16,9,9);
|
||||
$mpdf->SetImportUse();
|
||||
|
||||
$mpdf->SetDisplayMode('fullpage');
|
||||
|
||||
$mpdf->SetCompression(false);
|
||||
|
||||
// Add First page
|
||||
$pagecount = $mpdf->SetSourceFile('sample_basic.pdf');
|
||||
|
||||
$crop_x = 50;
|
||||
$crop_y = 50;
|
||||
$crop_w = 100;
|
||||
$crop_h = 100;
|
||||
|
||||
$tplIdx = $mpdf->ImportPage(2, $crop_x, $crop_y, $crop_w, $crop_h);
|
||||
|
||||
$x = 50;
|
||||
$y = 50;
|
||||
$w = 100;
|
||||
$h = 100;
|
||||
|
||||
$mpdf->UseTemplate($tplIdx, $x, $y, $w, $h);
|
||||
|
||||
$mpdf->Rect($x, $y, $w, $h);
|
||||
|
||||
$mpdf->Output('newpdf.pdf', 'I');
|
||||
|
||||
exit;
|
||||
|
||||
|
||||
?>
|
Loading…
Add table
Add a link
Reference in a new issue