WP Manifestindependent plugin directory
manifest / content / print-terapirekommendationer

Print Terapirekommendationer archived

Plugin to create a printable PDF with chapters from Terapirekommendationer 📖

by David Öhlin · github.com/regionhalland/print-terapirekommendationer · website

0stars
0forks

Install

No release zip yet. The repository archive installs, but the folder name will carry the branch suffix and updates will not flow:

wp plugin install https://github.com/regionhalland/print-terapirekommendationer/archive/refs/heads/master.zip

Allows editors to create a PDF with chapters from Terapirekommendationer

Installation

Installing PrinceXML on the server

This plugin uses PrinceXML to create the PDF file. It needs to be installed on the server. The plugin will look for the installed Prince binary in /usr/bin/prince. If it's installed elsewhere, update this line with the correct path.

Follow the instructions below or the official instructions for installing PrinceXML on Ubuntu.

  1. Download the installation package somewhere on your server:

    $ cd ~
    $ wget https://www.princexml.com/download/prince_12.2-1_ubuntu18.04_amd64.deb

    All available versions of PrinceXML can be found here.

  2. Install gdebi on the server:

    $ sudo apt install gdebi
  3. Install the downloaded package using gdebi:

    $ sudo gdebi ~/prince_12.2-1_ubuntu18.04_amd64.deb
  4. Make sure that PrinceXML is installed. The following command should return a version number and some information about the package:

    $ prince --version

Installing the plugin

  1. In your theme or Wordpress site, install the plugin via Composer:
    $ composer require regonhalland/print-terapirekommendationer

Development

Use gulp to build assets. The following gulp tasks are defined:

  • watch - Watch for changes in the ./src directory.
  • build - Minifies and compiles assets into the ./dist directory.

Usage

Make sure that the plugin is activated under Plugins → Print Terapirekommendationer.

Go to Settings → Print Terapirekommendationer, select the chapters you want to print and click Ladda ner PDF.

The PDF will be generated and downloaded automatically.