Luigi Micco

Strumenti Utente

Strumenti Sito

Barra laterale

I miei progetti


Se quello che hai trovato in queste pagine ti e\' stato in qualche modo d\'aiuto, puoi contribuire con una donazione!


oppure puoi cliccare su uno dei banner presenti qui.


Bookcreator Plugin

Allow to select some pages and create a book (PDF or text)

Download and Installation

Download and install the plugin using the DokuWiki Plugin Manager using the URL given above. Refer to :DokuWiki Plugins on how to install plugins manually.


The bookcreator plugin allow to select some pages from wiki and export to create a little book PDF or text (like a similar function of Wikipedia)

The component for syntax, displays the list of pages selected for exporting and manage selections; the component for action, handle the selection by a add/removing pages, show a toolbar (like a similar toolbar of Wikipedia).

On the list of selected pages, You can use drag and drop to change the order, save your selection for restore in a second time or share with other users.

At this moment only available Italian, French, English and German language, but it's easy to add you own language.

To work, this plugin needs cookies; the PDF export required Dw2pdf plugin; the TEXT ONLY export required text plugin.


To use this plugin, use these two simple ways:




in the page 'wiki:ebook' (create it first).

With ~~BOOK~~ You can show and manage your list of selected pages

  • Reset all selection
  • Exclude a page from list
  • View the excluded pages and “include” them back
  • Create the PDF book on selected pages
  • Create a printable version of selected pages
  • Extract only text of selected pages
  • Drag and drop to change exporting order of page (use Tool-Man JavaScript library )
  • Set a title for the PDF document
  • Save and restore selections on a specific namespace (use ACL's rights)

With ~~ARCHIVEBOOK:number&sort~~ You can show a list of saved selections (books) anywhere into your wiki

  • Restore a selection to manage/export again
  • sort by date/title
  • show only first number selections

Optionally you can specify the number of selections to display and the order. Default is 10 items ordered by date (first last updated). Each of selection is linked to book's page for it.


To add or remove a page to selection, you simply need to call the page passing it a “do=addtobookPHP argument. The easiest way to implement this is to add a button or similar somewhere in your template design.

Default template

Use the following to add another button in the upper or bottom button row of the default template1)

1) In /lib/tpl/default/main.php, there are two divs that contain some buttons:
. Just insert the HTML code inside one of the two divs (left or right) )) <code html> <form class=“button” method=“get” action=“<?php wl($ID)?>”>
  <input type="submit" value="Add/Remove selection" class="button" />
  <input type="hidden" name="do" value="addtobook" />
  <input type="hidden" name="id" value="<?php echo $ID?>" />


When using the template “monobook for DokuWiki”, to have an Add/Remove link, in /user/tabs.php, use this code
//pdfbook plugin: add/remove selection
if (file_exists(DOKU_PLUGIN."bookcreator/action.php") &&
    $_monobook_tabs["tab-bookcreator"]["text"] = "Add/Remove to selection";
    $_monobook_tabs["tab-bookcreator"]["href"] = wl(getID(), array("do" => "addtobook"), false, "&");

Version history

  • 2010-04-19 (current)
    • add support for ARCHIVE mode
    • rewritten part of code to avoid conflict with other scripts
    • support for use ACL's permissions on pages and book's namespace
  • 2010-04-15
    • some bugs removed (thanks to Karl for tips)
    • allow set wich user's group can save/remove selections
    • hide list of selections if empty
  • 2010-04-15
    • allow to export selection to a text only version (text plugin required)
    • solved problems with cache system
  • 2010-04-14
    • admin side configuration
    • toolbar like Wikipedia “Book creator”
    • support for “Help page
    • allow to set a title for the PDF document (see Dw2pdf plugin update)
    • allow to save and restore selections
    • allow to export selection to a printable version

Changing the order of wiki pages

To change the order of wiki pages in your book, simply move the pages in the list. To do so, hover over the page title to move, click and drag it to the new location. Release the mouse button to finish moving the page to its new location.

Saving books

Format of stored book pages: when you save a book, it is stored in the format shown below.
====== MyBookName ======
  * [[:first_pages]]
  * [[:second_page]]
  * .....
  * [[:last_page]]
You can also manually create a book from scratch by using the same format. To create a book from scratch, start a new page such as wiki:ebook:mybookname (default). The namespace can be changed at admin side configuration.
dokuwiki/bookcreator.txt · Ultima modifica: 21/03/2019 22:44 (modifica esterna)

Strumenti Pagina