Loading...
 
Since Tiki18, mPDF is the recommended PDF generator


For many years, wkhtmltopdf was the best available option. mPDF is vastly superior. wkhtmltopdf remains an optional available to Tiki, and thus, the information below is kept.
Image

wkhtmltopdf

wkhtmltopdf is an open source (LGPLv3) command line tool (Simple shell utility) to render(convert) HTML into PDF using the QT Webkit rendering engine. It runs entirely "headless" and do not require a display or display service. There is also a C library.
Source: http://wkhtmltopdf.org

There are two options (wkhtmltopdf 0.13 aims to simplify this)

  • standard: fewer features, requires X (and if your GNU/Linux OS is virtualized, it perhaps won't work)
  • patched QT: more features, doesn't require X (headless)

OpenHub

Configure

To configure with Tiki, go to General » General Settings admin panel (tiki-admin.php?page=general&cookietab=2) and set "PDF from URL" to "WebKit (wkhtmltopdf)". Then in the "WebKit path" insert for example this full path to the executable file: /var/local/bin/wkhtmltopdf-amd64 (on a Linux 64-bit system, the path can be different depending on the installation).

To know what “WebKit path” to provide
which wkhtmltopdf

which will report something like:
/usr/local/bin/wkhtmltopdf


Installation for various operating systems

If using wkhtmltopdf v 0.13. with no X11 window system
(...)
 /**
     * @param $url
     * @return mixed
     */
    private function webkit( $url )
	{
(...)
		// Run shell_exec command to generate out file
		// NOTE: this requires write permissions
		$quotedFilename = '"'.$filename.'"';
		$quotedCommand = '"'.$this->location.'"';
		
		`xvfb-run $quotedCommand -q $arg $quotedFilename`;

Issues

  • There might be problems for incorporating images or external content to the pdf file. Please see the wkhtmltopdf documentation.
  • If you are having issues with password protected pages, trying activating Token Access


Collection of References on doc.tiki.org

  • Print general info about printing
  • PDF general overview about PDF creation in Tiki
  • mPDF create PDFs from Tiki content (advanced library that works even on shared hosting). Recommended for Tiki18+
  • PluginPDF alter default settings of mPDF per wiki page
  • PluginPDFPageBreak add a page break for PDFs created with mPDF
  • PluginMediaPlayer display PDF file from file gallery
  • PDF.js viewer PDF.js from Mozilla
  • ViewerJS: a script to view PDFs and ODFs, which bundles WebODF
  • PluginArchiveBuilder Generate a zip file, including PDFs from wiki pages
  • WeasyPrint A PDF generation option in Python
  • wkhtmltopdf create PDFs from Tiki content (needs root installation)
  • dompdf once used for PDF print of slideshows

Aliases

wkhtml2pdf
wkhtmltoimage

doc.tiki.org

Bootstrap AdminGuide UserGuide

Keywords

Keywords serve as "hubs" for navigation within the Tiki documentation. They correspond to development keywords (bug reports and feature requests):

Accessibility (WAI and 508)
Accounting
Articles and Submissions
Backlinks
Banners
Batch
BigBlueButton audio/video/chat/screensharing
Blog
Bookmark
Browser Compatibility
Link Cache
Calendar
Category
Chat
Clean URLs
Comments
Communication Center
Compression (gzip)
Contacts (Address Book)
Contact us
Content Templates
Contribution
Cookie
Copyright
Credit
Custom Home and Group Home Page
Date and Time
Debugger Console
Directory of hyperlinks
Documentation link from Tiki to doc.tiki.org (Help System)
Docs
Draw
Dynamic Content
Dynamic Variable
External Authentication
FAQ
Featured links
File Gallery
Forum
Friendship Network (Community)
Gmap Google maps
Groups
Hotword
HTML Page
i18n (Multilingual, l10n, Babelfish)
Image Gallery
Import-Export
Install
Integrator
Interoperability
Inter-User Messages
InterTiki
Kaltura video management
Karma
Live Support
Login
Logs (system & action)
Look and Feel
Lost edit protection
Mail-in
Map with Mapserver
Menu
Meta Tags
Mobile Tiki and Voice Tiki
Mods
Module
MultiTiki
MyTiki
Newsletter
Notepad
Payment
Performance Speed / Load
Permissions
Platform independence (Linux-Apache, Windows/IIS, Mac, BSD)
Polls
Profiles
Profile Manager
Report
Toolbar
Quiz
Rating
Feeds
Score
Search engine optimization
Search
Search and Replace
Security
Semantic links
Shadowbox
Shadow Layers
Share
Shopping cart
Shoutbox
Slideshow
Smiley
Social Networks
Spam protection (Anti-bot CATPCHA)
Spellcheck
Spreadsheet
Stats
Surveys
Tags
Task
Tell a Friend, alert + Social Bookmarking
TikiTests
Theme CSS & Smarty
Trackers
Transitions
TRIM
User Administration including registration and banning
User Files
User Menu
Watch
WebDAV
Webmail
Web Services
Wiki History, page rename, etc
Wiki Plugin extends basic syntax
Wiki Syntax
Wiki structure (book and table of content)
Workspace
WSOD
WYSIWYCA
WYSIWYG
XMLRPC

Tiki Newsletter

Delivered fresh to your email inbox!
Newsletter subscribe icon
Don't miss major announcements and other news!
Contribute to Tiki
Show php error messages