Loading...
 
Skip to main content

History: Online Publishing House - Output formats

Source of version: 131 (current)

Copy to clipboard
Which way(s) should we go for the ((Online Publishing House)), in terms of going from Tiki content to a consumable format:
* [http://en.wikipedia.org/wiki/Print_on_demand|Print on demand (POD)] 
* [http://en.wikipedia.org/wiki/E-book|e-book]
* PDF
* EPUB
* Mobile App
* etc.

__((mPDF)) is the selected PDF to HTML output tool. Also, an integration has been added with ((PhantomJS)) for ((Browser automation)), including ((Converting dynamic JavaScript content into static assets|converting some JavaScript-generated content into static content)) for use by mPDF for printing.__

The research below is kept for posterity. 




For background info, see: [http://www.wikipublisher.org/wiki/?n=BookGuide.BookGuide&action=publish&ptype=book&format=makepdf|How to Produce a Book]

This will also be useful for ((Business Plans)). Let's review some potential options

! Booki which became Booktype

Booki uses: WYSIWYG HTML -> [https://www.openhub.net/p/objavi|Objavi] -> PDF, ODT or EPUB.

[http://www.booki.cc/booki-user-guide/core-components/|Objavi takes Booki-zip files from Booki and currently outputs to PDF (web readable, book formatted, and newsprint formatted), ODT, and EPUB.]

We would do: Wiki syntax (with some relevant logic) -> ((HTML5)) with flat output -> [https://www.openhub.net/p/objavi|Objavi] -> PDF, ODT or EPUB.

This is already ((doc:PDF|how Tiki does it with wkhtmltopdf)) but it's pretty basic.

https://www.openhub.net/p/booktype
https://www.openhub.net/p/objavi
https://github.com/booktype/BookJS
https://github.com/sourcefabric/Booktype/blob/2.0/README.md
http://opensource.com/education/15/3/open-source-book-publishing

! Wikipublisher
http://www.wikipublisher.org/
https://www.ohloh.net/p/wikipublisher

How Wikipublisher seems to do it: Wiki syntax -> ((LaTeX)) -> PDF

How we would do it: (Parser needs to be reworked)
* Wiki syntax (with some relevant logic) -> ((HTML5)) 
* Wiki syntax (with some relevant logic) -> [http://www.wikipublisher.org/wiki/Wikipublisher/WikibookDTD|wikibook XML] -> ((LaTeX)) -> PDF

Interesting links
* http://www.wikipublisher.org/wiki/WikiSym/WikipublisherProject
* http://www.wikipublisher.org/wiki/Wikipublisher/About
* http://www.wikipublisher.org/wiki/Wikipublisher/BasicFeatures
* http://www.wikipublisher.org/wiki/Wikipublisher/WhyWeNeedWikipublisher
* http://www.wikipublisher.org/wiki/Wikipublisher/WikipublisherIsUnique
* http://www.wikipublisher.org/wiki/Wikipublisher/WikipublisherTechnologies
* http://www.wikipublisher.org/wiki/Wikipublisher/TypesettingEngine
* http://www.wikipublisher.org/wiki/Wikipublisher/WikibookDTD
* http://www.wikipublisher.org/wiki/Issues/00087

This will increase desire for a WYSIWYG editor which maintains wiki syntax.
How can we produce an EPUB or a .odt in this process?

! Miktex
{HTML()}<script type='text/javascript' src='https://www.openhub.net/p/miktex/widgets/project_factoids_stats?format=js'></script>{HTML}

! Pressbooks
PressBooks is a book-making tool that outputs as: epub, print-ready PDF, HTML, and InDesign-ready XML. Built on WordPress.
* http://pressbooks.com
* http://nextmontreal.com/book-oven-to-pressbooks/
* http://blog.pressbooks.com/?p=211
* http://www.slideshare.net/mackinaw/pressbooks-2015

They also use (used?) Wikipublisher
* https://groups.google.com/group/wikipublisher/browse_thread/thread/1c821fd8943326cb?hl=en
* https://groups.google.com/group/wikipublisher/browse_thread/thread/af9a4584cf90118a?hl=en

And more recently are supporting mPDF
https://github.com/pressbooks/pressbooks/search?q=mpdf&type=Issues&utf8=%E2%9C%93


! WeasyPrint
WeasyPrint is a visual rendering engine for HTML and CSS that can export to PDF.
* http://weasyprint.org/
* https://www.redhat.com/archives/publican-list/2012-August/msg00001.html
* https://admin.fedoraproject.org/pkgdb/package/weasyprint/

{HTML()}<script type="text/javascript" src="https://www.openhub.net/p/597784/widgets/project_factoids_stats.js"></script>{HTML}
! Book creator and PediaPress
Rather than trying to fetch all pages selected for printing (curent tiki-print) have a look at MediaWiki's http://en.wikipedia.org/wiki/Special:Book which uses http://en.wikipedia.org/wiki/TeX (only for math)
Some technical descriptions on how MediaWiki's book creator works and which problems may occur: http://en.wikipedia.org/wiki/Help:Books/for_experts

export format: PDF or ODF or [http://openzim.org/|ZIM]
http://en.wikipedia.org/wiki/Help:Books/Frequently_Asked_Questions


! WikiBooks HTML output
* http://en.wikibooks.org

! All options on packagist
* https://packagist.org/search/?tags=pdf 
** https://packagist.org/packages/psliwa/php-pdf 
** https://packagist.org/packages/easybook/easybook 
** https://packagist.org/packages/rev42/revpdf-lib 

! Using Apache FOP
* http://xmlgraphics.apache.org/fop/
* https://www.ohloh.net/p/fop

! dompdf
* [https://groups.google.com/forum/m/#!topic/dompdf/K0rhecOOyOY|0.7.0 Beta release]
* http://dompdf.github.io/ is already part of Tiki via ((doc:Slideshow)) export features in ((doc:Tiki9))
** [http://code.google.com/p/dompdf/wiki/Features|Features]
** [http://pxd.me/dompdf/www/examples.php#samples|Examples]
** [http://code.google.com/p/dompdf/issues/detail?id=211|Feature request for Table of Content]
** [http://code.google.com/p/dompdf/issues/detail?id=314|Feature request for SVG support]
* https://www.ohloh.net/p/dompdf
* http://raymondkolbe.com/2012/07/01/dompdf-in-zf2/
 
{HTML()}<script type="text/javascript" src="https://www.openhub.net/p/26823/widgets/project_factoids_stats.js"></script>{HTML}

! mPDF
* "mPDF is a PHP class which generates PDF files from UTF-8 encoded HTML. It is based on FPDF and HTML2FPDF, with a number of enhancements."
* License: GPL
* https://github.com/mpdf/mpdf
* https://packagist.org/packages/mpdf/mpdf
* http://www.hotscripts.com/listings/reviews/102680/
* [http://sourcefabric.booktype.pro/booktype-20-for-authors-and-publishers/installing-a-pdf-renderer/|Booktype can use a variety of renderers to convert a book's HTML chapters into a single PDF file for export. mPDF 6.0 (http://www.mpdf1.com) is currently recommended, due to its extensive support for pre-press features including CMYK and spot colours, bleeds and crop marks, right-to-left and bi-directional text, and typographical hints in non-Latin scripts.]
http://mpdf1.com/


! Zend_Pdf
* "The Zend_Pdf component is a PDF (Portable Document Format) manipulation engine. It can load, create, modify and save documents. Thus it can help any PHP application dynamically create PDF documents by modifying existing documents or generating new ones from scratch."
** http://framework.zend.com/manual/1.12/en/zend.pdf.introduction.html

! TCPDF
* http://www.tcpdf.org/
** [http://www.tcpdf.org/examples/example_015.pdf|bookmarks] 
** [http://www.tcpdf.org/examples/example_058.pdf|SVG support] (which we need for Tiki ((Draw)).)
** [http://www.tcpdf.org/examples/example_014.pdf|Forms with JS]
** [http://www.tcpdf.org/examples/example_052.pdf|Digital signature certification]
** [http://www.tcpdf.org/examples/example_050.pdf|2D barcodes & QR-Code]. See also: ((Barcode and QR code))
** [http://www.tcpdf.org/examples.php|And many more...]

{HTML()}<script type="text/javascript" src="https://www.openhub.net/p/8391/widgets/project_factoids_stats.js"></script>{HTML}

! Mozilla2PS
* ((doc:Mod Mozilla2PS))
* http://acksyn.org/mozilla2ps/index.html
* [http://en.wikipedia.org/wiki/XULRunner|XULRunner]

! HTML2FPDF
There seems to be three with the same name:

* http://sourceforge.net/projects/html2pdf/ 
* http://sourceforge.net/projects/html2fpdf/
* http://sourceforge.net/projects/phphtml2pdf/ 
** [http://html2pdf.fr/en/default|HTML2PDF is a HTML to PDF converter written in PHP. It allows the conversion of valid HTML 4.01 in PDF format, and is distributed under LGPL. This library has been designed to handle mainly TABLE intertwined to generate invoices delivery, and other official documents. It does not yet have all the tags.]

! Horde PDF library
http://www.horde.org/libraries/Horde_Pdf

! wkhtmltopdf
* ((wkhtmltopdf))

{HTML()}<script type="text/javascript" src="https://www.openhub.net/p/59638/widgets/project_factoids_stats.js"></script>{HTML}

! node-wkhtmltopdf
https://www.openhub.net/p/node-wkhtmltopdf

! node-html-pdf
https://github.com/marcbachmann/node-html-pdf

! pdfmake
{HTML()}<script type="text/javascript" src="https://www.openhub.net/p/722038/widgets/project_factoids_stats.js"></script>{HTML}

! Docverter
* http://www.docverter.com/
Convert plain text documents written in HTML, Markdown, or LaTeX to PDF, Docx, RTF or ePub with a simple HTTP API.

! Chrome
We could do like this too:
https://github.com/hakimel/reveal.js#pdf-export

! HTML5 and PhantomJS
http://we-love-php.blogspot.de/2012/12/create-pdf-invoices-with-html5-and-phantomjs.html
! eZ Components - Document
* https://github.com/zetacomponents/Document

! PDF using Flash
* http://code.google.com/p/purepdf/
* https://www.ohloh.net/p/purepdf

! HPDF
* https://github.com/manuels/hpdf.js

! MarMatMak
* MarMatMak is short for « Marketing Material Maker »,
* http://www.bxlug.be/marmatmak
* https://www.ohloh.net/p/marmatmak

! Publican
https://www.openhub.net/p/publican

! Flying Saucer
* Uses iText
* {HTML()}<script type='text/javascript' src='https://www.openhub.net/p/xhtmlrenderer/widgets/project_factoids_stats?format=js'></script>{HTML}

! iText
* http://itextpdf.com/
{HTML()}<script type='text/javascript' src='https://www.openhub.net/p/itext/widgets/project_factoids_stats?format=js'></script>{HTML}

! ReportLab
In Python
https://www.openhub.net/p/reportlab
http://www.reportlab.com/opensource/

! xhtml2pdf
* In Python
https://github.com/xhtml2pdf/xhtml2pdf

{HTML()}<script type='text/javascript' src='https://www.openhub.net/p/xhtml2pdf/widgets/project_factoids_stats?format=js'></script>{HTML}

! speedata Publisher
{HTML()}<script type='text/javascript' src='https://www.openhub.net/p/speedatapublisher/widgets/project_factoids_stats?format=js'></script>{HTML}

! Output to ODF
* http://johnmacfarlane.net/pandoc/
* {HTML()}<script type="text/javascript" src="https://www.openhub.net/p/11854/widgets/project_factoids_stats.js"></script>{HTML}

! GrabzIT
* https://github.com/GrabzIt
* https://www.openhub.net/p/grabzit

! Epub
* http://www.phpclasses.org/package/6115-PHP-Create-ebook-in-EPUB-format-for-ex-Apple-iPad.html
* https://packagist.org/search/?q=epub&orderBys%5B0%5D%5Bsort%5D=downloads&orderBys%5B0%5D%5Border%5D=desc
* https://sourceforge.net/p/tiki2epub/code/HEAD/tree/trunk/
* https://gitlab.coko.foundation/pubsweet/html-epub
* https://github.com/wallabag/PHPePub
* https://github.com/blaetter/pepgen
* https://github.com/search?l=PHP&o=desc&q=epub&s=updated&type=Repositories
! AsciiDoc
* https://www.ohloh.net/p/asciidoc
AsciiDoc is a text document format for writing notes, documentation, articles, books, ebooks, slideshows, web pages, man pages and blogs. AsciiDoc files can be translated to many formats including HTML, PDF, EPUB, man page.

AsciiDoc is highly configurable: both the AsciiDoc source file syntax and the backend output markups (which can be almost any type of SGML/XML markup) can be customized and extended by the user.

https://plus.google.com/114112334290393746697/posts/CdXJt6hVn5A

{HTML()}<script type="text/javascript" src="https://www.openhub.net/p/719730/widgets/project_factoids_stats.js"></script>{HTML}
See also: ((Wiki Parser Revamp))

! Sphinx
http://www.sphinx-doc.org/
http://readthedocs.org/projects/sphinx/downloads/pdf/stable/

! jsPDF
{HTML()}<script type='text/javascript' src='https://www.openhub.net/p/GitHub-jsPDF/widgets/project_factoids_stats?format=js'></script>{HTML}

! An idea for mobile devices
See ((Online Publishing House - Mobile app))

-= Related links =-
* http://diethardsteiner.github.io/reporting/2015/02/17/CSS-for-print.html
* http://publicationstation.wdka.hro.nl/wiki/index.php/Research/all-in-one_publishing
* http://publicationstation.wdka.hro.nl/wiki/index.php/Research/Web-to-print
Show PHP error messages