DigitalDaz Posted August 30, 2017 Share Posted August 30, 2017 I'm currently creating a custom module to print out some stuff, completely unrelated to WHMCS I need to print a PDF and see that there is vendor/tecnickcom/tcpdf Can anyone tell me how I can use this within my module please. I think its goint ot be some sort of use thing but being as WHMCS itself is encrypted I cannot look at the source to see how they do it. TIA Daz 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted August 31, 2017 Share Posted August 31, 2017 I wouldn't expect WHMCS to be doing anything devilishly clever internally with this, you should take a look at the tcpdf documentation about creating PDF pages using PHP. you might find it easier for testing to add tcpdf to your module folder, then if/when you have it working there, try to do the same by accessing the files in the tecnickcom folder. 0 Quote Link to comment Share on other sites More sharing options...
WHMCS Developer WHMCS Andrew Posted August 31, 2017 WHMCS Developer Share Posted August 31, 2017 We don't change any of the files in the vendor directory for third parties. Anything there is stock. Anything we do override is done inside the WHMCS vendor folder and shouldn't affect you making custom PDFs using the TCPDF class directly. 0 Quote Link to comment Share on other sites More sharing options...
DigitalDaz Posted August 31, 2017 Author Share Posted August 31, 2017 We don't change any of the files in the vendor directory for third parties. Anything there is stock. Anything we do override is done inside the WHMCS vendor folder and shouldn't affect you making custom PDFs using the TCPDF class directly. Guys, thanks for the answer, maybe I worded my question wrong but what I was looking for that I managed to work out was this: $pdf = new \TCPDF; or in my case: $pdf = new \TCPDF(PDF_PAGE_ORIENTATION, PDF_UNIT, PDF_PAGE_FORMAT, true, 'UTF-8', false); 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.