rotatePdf

rotatePdf

ADVANCED / PREMIUM TRIAL

Rotates a PDF document.

Description
public rotatePdf (string $source, string $target, [array $options])

This method allows you to rotate a PDF document.

Parameters

source

Path to the PDF document.

target

Path to the resulting document.

options

The possible keys and values are:

key Type Description
annotations bool Import annotations (links, comments and others). Default as false.
degrees int Rotation, multiple of 90 (90, 180, 270). Default as 90.
useFixedAnnotationPositions bool Force annotation page link IDs. Useful when using PDF readers that don't detect all PDF contents automatically. Default as false.
Exceptions

File doesn't exist.

Code samples

Example #1

Release notes
  • phpdocx 15.5:
    • new method.