Skip to content
This repository has been archived by the owner on Dec 20, 2019. It is now read-only.

RegionHalland/print-terapirekommendationer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

69 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

Print Terapirekommendationer ๐Ÿ“–

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.

  1. Install gdebi on the server:
$ sudo apt install gdebi
  1. Install the downloaded package using gdebi:
$ sudo gdebi ~/prince_12.2-1_ubuntu18.04_amd64.deb
  1. 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.