encryptPDF

encryptPDF

PREMIUM BASIC / ADVANCED

Encrypts a PDF file.

Description
public void encryptPDF(String source, String target, String password) throws Exception

This method allows to encrypt a PDF file. The final user will be prompted to introduce the password included in the $options array to access the contents of the resulting PDF file.

Parameters

source

Path to the PDF document that you want to encrypt.

target

Path to the resulting encrypted PDF document.

Code samples

Example #1

The resulting Word document looks like: