I'm about to integrate dompdf into my printer-friendly pages module.
According to INSTALL.TXT of the print module I downloadad dompdf (0.5.1) and copied it into sites\all\modules\print. My problem is probably that I do not know how to 'Edit dompdf_config.inc.php to fit your installation'.
I tried with the line define("DOMPDF_DIR", realpath(dirname(sites/all/modules/print))); but it I run into the error 'Parse error: syntax error, unexpected ')' in C:\xampp\htdocs\sites\all\modules\print\dompdf_config.inc.php on line 56'.
My environment is windows, PHP5.2. Do I have to use \ instead of /?
Any further hints to get this running? Do I have to change anything of PHP?
Comments
Comment #1
jcnventuradompdf usually works out of the box.. I would put back the original dompdf_config.php file and see if it works like that.
Anyway, on your code above, you're missing the quotes around the path (inside the dirname call.
João
Comment #2
jcnventuraI would normally wait for a couple of days more and close the issue, but since you're so busy translating the module into German, I would like to refresh this.
Did you solve the problem?
João
Comment #3
FrankT commentedThanks for your patience. I did a fresh install of the module (sites\all\print) and copied dompdf to that place (so I have subdirectories icons, include, lib, tests, translations, www). I also went to the settings page >> PDF and marked the option for DOMPDF (so it looks like it was found by the module). I also deleted dompdf.php as mentioned in INSTALL.TXT. I did NOT make any changes in dompdf_config.inc.php.
Calling a PDF-Version from the start page generates the error
Fatal error: Call to undefined method domdocument::loadHTML() in C:\xampp\htdocs\sites\all\modules\print\include\dompdf.cls.php on line 284.The same error appears if a call pdf version from any node.
Comment #4
jcnventuraOh! You have the domdocument::loadHTML! Nice!
See #295026: Dompdf not working. I am marking this one as a duplicate now, as I have already pinpointed the problem in the other thread.
João