Document Viewer Plugin

Embed presentations, spreadsheets, PDFs and other documents

The Document Viewer Plugin allows you to use presentations, spreadsheets, PDFs and other documents in Foswiki without any external dependencies. No tricks, no conversions, no unexpected downtime from external services, and no plugins required - it happens to work just fine in all major browsers today.

Document Viewer Plugin uses viewerjs, which makes use of pdf.js and webodf to perform the rendering.

Supported formats

Preferences

Currently, there aren't any preferences to be configured.

Syntax

%DOCUMENTVIEWER{"filename.pdf" … params ...}%

Parameter Description Default
"<filename>" the name of an attached file to be displayed  
topic topic where the file is attached to current topic
format one of the ids 'portrait' (width=742, height=1024), 'landscape' (width=1024, height=742) or 'screen' (width=1024, height=768)  
width reader width 724
height reader height 1024

Installation

You do not need to install anything in the browser to use this extension. The following instructions are for the administrator who installs the extension on the server.

Open configure, and open the "Extensions" section. "Extensions Operation and Maintenance" Tab → "Install, Update or Remove extensions" Tab. Click the "Search for Extensions" button. Enter part of the extension name or description and press search. Select the desired extension(s) and click install. If an extension is already installed, it will not show up in the search results.

You can also install from the shell by running the extension installer as the web server user: (Be sure to run as the webserver user, not as root!)
cd /path/to/foswiki
perl tools/extension_installer <NameOfExtension> install

If you have any problems, or if the extension isn't available in configure, then you can still install manually from the command-line. See https://foswiki.org/Support/ManuallyInstallingExtensions for more help.

Dependencies

None

Change History

28 Apr 2022 docu fixes
02 Sep 2016 make it backwards compatible
27 Sep 2015 fixed masking warnings
16 Aug 2015 Initial version

This site is powered by FoswikiCopyright &© by the contributing authors. All material on this site is the property of the contributing authors.
Ideas, requests, problems regarding Ütopya? Send feedback
This website is using cookies. More info. That's Fine