Skip to main content
Version: Next

PDF Editable

This editable requires Ghostscript installed on your server, which renders the preview image of the embedded document. Non-PDF assets (doc, xls, ...) additionally require LibreOffice or Gotenberg to be converted to PDF first. See System Requirements and Optional System Dependencies.

General

The PDF editable allows you to embed asset documents (pdf, doc, xls, ...) into documents.

Configuration

NameTypeDescription
thumbnailstring/arrayThumbnail config (name or array) for the preview image
uploadPathstringTarget path for (inline) uploaded images

Methods

NameReturnDescription
getData()arrayReturns all stored data for this editable
isEmpty()booleanWhether the editable is empty or not
getElement()AssetReturns the assigned Asset Document

Examples

Basic usage

<div class="pdf">
{{ pimcore_pdf("myPdf", {"width": 640}) }}
</div>

This looks like the following in editmode:

PDF editable - the empty areaPDF editable - the empty areaPDF editable - the empty area

A user can now drag documents there from the Assets tree:

PDF editable - drag a documentPDF editable - drag a documentPDF editable - drag a document