Enabling printing and downloading

This tutorial shows how to enable printing in FSI Pages Add-On and how to let users download different PDF files for printing and off-line reading.

Printing from FSI Pages

Enabling the print feature in FSI Pages is quite simple. In the *.xml file of your FSI Viewer instance, add 2 lines to the configuration as shown:

 

By setting the print value to true, FSI Pages will display a print button. The second parameter Printresoultion sets the image width in pixel, which FSI Viewer will retrieve from the imaging server. In this example, the image being printed will be 1024 pixels wide, the correct height of the image will automatically be calculated by the imaging server.

Having FSI Pages set up this way, the user can easily print an image of each page. The “Current View” option is enabled, when the user zoomed a page. As FSI Viewer prints an image retrieved from the imaging server, the maximum resolution possible depends on the Real-time templates defined in the Imaging server.

Downloading Files from FSI Pages

In addition to the print option you can offer for download PDF or JPEG files from within the FSI Pages user interface. The following file can be presented for download:

  • the entire catalog (PDF)
  • a certain range of pages as defined in “Chapters” plug-in
  • a double page (PDF)
  • a single page (PDF or JPEG)

Offering JPEGs for Download

Offering JPEGs for download requires no special preperations as the images will automatically be retrieved from the imaging server. You only need to enable the “Download” option by adding the following parameters to your FSI Pages configuration file:

 

Offering PDF files for Download

Offering a PDF document containing all pages of a document is as easy as adding the URL to the corresponding PDF file to your FSI Viewer Configuration:

 

Offering PDF files of individual Pages for Download

In order to enable the user to download a PDF document containing the page currently viewed in FSI Pages, the XML based data for a page needs to contain the corresponding URL or file name to that document.
FSI Pages Converter will add the related info to the IPTC Data, when enabling the “PDF Output” Option.

The easy way with FSI Pages Converter

If you are using FSI Pages Converter to convert your PDF document, you only need to enable the “PDF Output” option in FSI Pages Converter and FSI Pages Converter will split your source document into multiple PDF documents:

You will then need to upload these files to some web server to provide them for download and add the FSI Pages parameter SaveURLPrefix specifying the URL to the directory on your server, containing these files.

If you uploaded the PDF documents created by FSI Pages converter to your server and the URL to download the files is e.g. http://www.domain.com/downloads/catalog/*.pdf then your configuration should look like this:

 

Now the user can download a single page PDF file of the entire catalog and print it, too. This may become handy, if, for some reason, the quality of the images being printed by FSI Viewer may not be sufficient, e.g. rasterized text in images compared to vector based text in the PDF files.

Please note:
If you use the FSI Pages parameters SaveUrlPrefix and/or SaveUrlSuffix all “file” attribute values will be prefixed and/or suffixed with the values you specified. This way you can enter the file names only and provide the path to the files using the FSI Pages parameter SaveUrlPrefix.

Downloading PDF Files for Chapters

If your document is separated into logical parts (e.g. chapters or product groups), you might want to enable the user to download parts of the document. In this case you need to use the FSI Viewer plug-in Chapters which enables the user to select and go to a predefined section in your document. For each section you can specify a separate document to offer for download. This way the user will be presented an option to download the current section (chapter) in the “Save” dialog:

In this case we have a subfolder in http://www.domain.com/downloads/catalog/ named chapters which hosts the PDF files for the chapters. Note that the SaveURLPrefix helps us here, too.

Now the user has a full featured save menu with PDF files.
Please note: For technical reasons it is not possible to have “Both pages” and single pages available as PDF at the same time. If you offer both pages in a single PDF file, the left and right page will be available as JPEG only.