Skip to content

Commit aa5d837

Browse files
committed
First attempt at using DOMPDF project as dependency.
1 parent e234ac3 commit aa5d837

File tree

3 files changed

+8
-7
lines changed

3 files changed

+8
-7
lines changed

composer.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,12 @@
1212
}
1313
],
1414
"require": {
15-
"php": ">=5.3.0"
15+
"php": ">=5.3.0",
16+
"dompdf/dompdf": "dev-master"
1617
},
1718
"autoload": {
1819
"psr-0": {
1920
"DOMPDFModule": "src/"
2021
}
2122
}
22-
}
23+
}

config/module.config.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
*
3232
* *Please note the trailing slash.*
3333
*/
34-
'font_directory' => __DIR__ . '/../vendor/dompdf/lib/fonts/',
34+
'font_directory' => __DIR__ . '/../../vendor/dompdf/lib/fonts/',
3535

3636
/**
3737
* The location of the DOMPDF font cache directory
@@ -41,7 +41,7 @@
4141
* It contains the .afm files, on demand parsed, converted to php syntax and cached
4242
* This folder can be the same as DOMPDF_FONT_DIR
4343
*/
44-
'font_cache_directory' => __DIR__ . '/../vendor/dompdf/data/dompdf/cache/',
44+
'font_cache_directory' => __DIR__ . '/../../vendor/dompdf/data/dompdf/cache/',
4545

4646
/**
4747
* The location of a temporary directory.
@@ -64,7 +64,7 @@
6464
* direct class use like:
6565
* $dompdf = new DOMPDF(); $dompdf->load_html($htmldata); $dompdf->render(); $pdfdata = $dompdf->output();
6666
*/
67-
'chroot' => realpath(__DIR__ . '/../vendor/dompdf/'),
67+
'chroot' => realpath(__DIR__ . '/../../vendor/dompdf/'),
6868

6969
/**
7070
* Whether to use Unicode fonts or not.
@@ -285,4 +285,4 @@
285285
'ViewPdfStrategy' => __NAMESPACE__ . '\Mvc\Service\ViewPdfStrategyFactory',
286286
)
287287
),
288-
);
288+
);

src/DOMPDFModule/Service/DOMPDFFactory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ public function createService(ServiceLocatorInterface $serviceLocator)
7272
$config = $config['dompdf_module'];
7373

7474
if (defined('DOMPDF_DIR') === false) {
75-
define("DOMPDF_DIR", __DIR__ . '/../../../vendor/dompdf');
75+
define("DOMPDF_DIR", __DIR__ . '/../../../../vendor/dompdf');
7676
}
7777

7878
if (defined('DOMPDF_INC_DIR') === false) {

0 commit comments

Comments
 (0)