To PDF Add-On
This addons converts TWiki topics into PDF`s. Comparing to GenPDF or others, its main goal yet is to support CSS as far as possible and therefore the PDF should just loook like the original topic
This Add On is based on GenPDF and finally, it should have the same great functionality as GenPDF. The reason its seperated is, because it will take some time to finish ToPDF to be that "user friendly" for every TWiki user, as GenPDF is. So ToPDF will exist as a alternative converter until the full functionallity of GenPDF is ported/combined.
- the whole script is based on TWiki:Plugins/GenPDFAddOn
- as backend it uses html2pdf, a php5 script to convert html files into PDFs. It supports CSS 2.0 and even float content.
Add-On Installation Instructions
You do not need to install anything on the browser to use this add-on. The following instructions are for the administrator who installs the add-on on the server where TWiki is running.
Dependecies( Tested with linux, should work under windows too)
- PHP5 as client modes, so for the use in the command line
- Ghostscript-GPL ( worked with 8.61, please add other versions here, if you tested it )
- pdflib ( worked with 7.0.2, please add other versions here, if you have tested it )
- gnu-gs-fonts-std: Ghostscript Standard Fonts
- gnu-gs-fonts-other: Ghostscript Extra Fonts
- Download the ZIP file from the Add-on Home (see below)
- Install all dependecies
ToPDFAddOn.zip in your twiki installation directory. Content:
| File: || Description: |
| Add-on topic |
| Add-on topic repository |
| html2pdf conversion Script including .htaccess which permits any browser-use |
| Add-on script |
- BASEURL: Set your url, you use with TWiki. This is used for CSS files and stuff
- TYPE1_FONTS_REPOSITORY: your absolute path to the ghostscript fonts ( e.g /usr/share/fonts/default/ghostscript/ )
- DEFAULT_ENCODING: set this to your twik encoding
- GS_PATH: your ghostscript path ( usually /usr/bin/gs )
- Set your header and footer if needed
- Add the PDF button to your viewtopicactions.skin.tmpl ( or somewhere else )
- Test if the installation was successful:
- open view/TWiki/ToPDFAddOn and click this link and hopefully you get a PDF of the ToPDFAddOn topic.
Related Topic: TWikiAddOns
- Set SHORTDESCRIPTION = Converts topics ( TML ) into PDF
- 01 Jun 2008