Integration manual

  1. Installation
  2. Choice of image generation engine


  • Stop the server
  • Download jars from plugin and add them (ametys-plugin-flipbook-1.4.0.jar and ametys- plugin-flipbook-resources-1.4.0.jar) in the WEB-INF/lib directory of your application. Ametys

  • Add the menu for inserting interactive PDF into the file WEB-INF/params/cms-ribbon-default.xml. The button identifier is org.ametys.flipbook.editor.Insert
    Add it to the "Insert" group in the contextual editing tab (org.ametys.cms.content.EditionTab)

	<tab label="plugin.cms:RIBBON_TABS_TAB_CONTENT_EDIT_LABEL" id="org.ametys.cms.content.EditionTab" contextualColor="1" contextualGroup="Z" contextualLabel="plugin.cms:RIBBON_TABS_TAB_CONTENT_EDIT_LABEL">
			<group label="plugin.cms:RIBBON_TABS_TAB_CONTENT_EDIT_GROUPS_GROUP_INSERT_LABEL" icon="">
					<control id="org.ametys.flipbook.editor.Insert"/>

Attention ! Si le groupe contient une description <large>, <medium> et <small> , il faut ajouter le bouton dans les 3.


  • Restart the server

Choice of image generation engine

Displaying a PDF file involves two phases: the pages of the PDF file are extracted as PNG images, then the viewer displays them.

As the generation of pages as images is an extension point, several options are available for this operation:

  • Via the java Apache PDFBox library
  • Using an external command line program, such as pdftoppm
Extraction motorExtension nameOperating systemsExtraction quality
Bookstore java Apache PDFBox


External command-line program


Linux and MacOS onlyvery good

The choice of image generation engine is made in the "" configuration file.

UsingApache PDFBox

This is the default solution because it's the easiest to implement: there's no external program to install, the library is already supplied with CMS and works with all operating systems. However, the quality of extracted images is not as good as when using an external program.

To use it, simply leave the "WEB-INF/param/runtime.xml" file empty for the extension point. "org.ametys.plugins.flipbook.Document2ImagesConvertor" (or use the org.ametys.plugins.flipbook.convertor.Pdfbox).

Using an external command-line program (pdftoppm)

The solution can work with any command-line program that extracts pages from a PDF file as numbered PNG images. This section describes how to use the pdftoppm program.

This solution has the advantage of quality: the extracted images are perfectly in line with the original PDF document. However, it requires the installation of an external program, and cannot be used in a Windows environment.

To use this solution, enter the following line in your application's"WEB-INF/param/runtime.xml " file


This solution is preferable if the environment permits.

Program installation

You then need to install the program that makes the pdftoppm command available. The most widely used is Poppler.

To install this program under Debian/Ubuntu :

$ sudo apt-get install poppler-utils


Using an external command line program requires a configuration parameter corresponding to the conversion command: see the Administration Manual.





Back to top