smarthost Posted May 12, 2010 Share Posted May 12, 2010 I try to add this code: $certificate="file:///data/web/virtuals/dev.smarthost.cz/secure/smarthost.crt"; $info = array( 'Name' => 'TCPDF', 'Location' => 'Office', 'Reason' => 'Testing TCPDF', 'ContactInfo' => 'http://www.tcpdf.org', ); $pdf->setSignature($certificate,$certificate,'','',2,$info); to invoicepdf.tpl in my template direcory, but document is still unsigned. What I do wrong? 0 Quote Link to comment Share on other sites More sharing options...
MH-Stefan Posted May 19, 2011 Share Posted May 19, 2011 Sorry for resurrecting an old thread, but since the TCPDF library has been updated with v4.5, I assume that digitally signing invoices should now be possible (somehow). Unfortunately, the code above still doesn't work. Any suggestions would be greatly appreciated. Most EU-based companies are legally required to digitally sign invoices, so this function is quite important. 0 Quote Link to comment Share on other sites More sharing options...
xuser Posted May 25, 2011 Share Posted May 25, 2011 (edited) Matt, One of my client's also reported the same issue. Following is his ticket that he raised with me. ~~~~~~~~~~~~ when i login to my client area to charge my account with Paypal ( in "Add Fund" section ) ,i see the folowing error message : " TCPDF ERROR: Could not include font definition file: custom " so i cant charge my account when i recieve this error. ~~~~~~~~~~ Edited May 25, 2011 by xuser 0 Quote Link to comment Share on other sites More sharing options...
xuser Posted May 25, 2011 Share Posted May 25, 2011 and some cron jobs are also giving this error message: ~~~~~~~~~~~~~~~~~ Cron <username@congo> php -q /home/username/public_html/billing/admin/cron.php <strong>TCPDF ERROR: </strong>Could not include font definition file: custom ~~~~~~~~~~~~~~~~~ 0 Quote Link to comment Share on other sites More sharing options...
ahosting Posted June 15, 2011 Share Posted June 15, 2011 Try change Setup> General settings > Invoices - TCPDF Font Family from custom to Helvetica 0 Quote Link to comment Share on other sites More sharing options...
drtduarte Posted October 3, 2011 Share Posted October 3, 2011 Were you guys able to configure the digital signature? 0 Quote Link to comment Share on other sites More sharing options...
stormy Posted December 8, 2011 Share Posted December 8, 2011 I'm very interested in this as well. We are getting away with regular PDF invoices, but pretty soon the taxman is going to be asking us to do this. It's the law, after all! 0 Quote Link to comment Share on other sites More sharing options...
laszlof Posted December 8, 2011 Share Posted December 8, 2011 Seems to work fine in my tests. Heres the code I added to invoicepdf.tpl // Sign PDF $certificate = 'file://'.ROOTDIR.'/test.crt'; $info = array( 'Name' => 'Test', 'Location' => 'Test', 'Reason' => 'Signing Invoice', 'ContactInfo' => 'Test'); $pdf->setSignature($certificate, $certificate, $info); The certificate contains both the private key and certificate, thats why its defined twice in the setSignature() function. More info on what needs to be passed to setSignature() can be found here: http://www.tcpdf.org/doc/classTCPDF.html#a16ca73a301730e6e4dd368628bceeb75 0 Quote Link to comment Share on other sites More sharing options...
stormy Posted December 9, 2011 Share Posted December 9, 2011 Ok, that's way above my head. Last time I looked it wasn't even possible to sign invoices digitally. Now that it is, I hope someone can put together a module to do it. I'm going to put in a request in the appropriate subforum 0 Quote Link to comment Share on other sites More sharing options...
laszlof Posted December 11, 2011 Share Posted December 11, 2011 Here ya go: http://forum.whmcs.com/showthread.php?p=207966 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.